HTML tool for adding subresource integrity hashes
npm install @dintero/sri-to-dist
A tool to add subresource integrity (SRI) hashes to HTML files.
``bash`
npm install -g @dintero/sri-to-distor
npx @dintero/sri-to-dist
`bash`
sri-to-dist -i input.html -o output.html
sri-to-dist --input input.html --output output.html --base-url https://example.com
- -i, --input : Input HTML file (required)-o, --output
- : Output HTML file (optional, defaults to stdout)-b, --base-url
- : Base URL for resolving relative paths (optional)-n, --no-remote
- : Optional flag, no remote sri files allowed-v, --verify
- : Optional flag, verify that all sri resources from input have correct sha384 hashes
MIT
Contact us at security@dintero.com
`bash`
npm install
npm run build
npm run test
npm link # This makes your package available globally for testing
Now you can run:
`bash`
sri-to-dist -i test.html
`bash``
npm login
npm publish
1. Enforce all commits to the master branch to be formatted according to the Angular Commit Message Format
2. When merged to master, it will automatically be released with semantic-release