UNPKG
helmet-csp-uc
Version:
latest (0.3.3)
0.3.3
0.3.2
0.3.1
0.3.0
Content Security Policy middleware.
github.com/zack-lin/csp
helmet-csp-uc
/
lib
/
make-policy-string.js
6 lines
(5 loc)
•
182 B
JavaScript
View Raw
1
2
3
4
5
6
module
.
exports
=
function
makePolicyString
(
directives
) {
return
Object
.
keys
(directives).
map
(
function
(
key
) {
return
[key].
concat
(directives[key]).
join
(
" "
); }).
join
(
";"
); };