https://github.com/krutsch/html-encrypt
Password protect a static HTML page without server
https://github.com/krutsch/html-encrypt
cli crypto html javascript password typescript
Last synced: 7 months ago
JSON representation
Password protect a static HTML page without server
- Host: GitHub
- URL: https://github.com/krutsch/html-encrypt
- Owner: Krutsch
- License: mit
- Created: 2024-09-09T15:15:23.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-04-16T16:03:01.000Z (8 months ago)
- Last Synced: 2025-05-12T04:12:18.050Z (8 months ago)
- Topics: cli, crypto, html, javascript, password, typescript
- Language: JavaScript
- Homepage: https://html-encrypt-demo.netlify.app
- Size: 367 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# html-encrypt
A zero config (and only optional minifiers as dependencies) to encrypt html files.
This is a heavy modified clone of [staticrypt](https://github.com/robinmoisson/staticrypt).
## Installation
```bash
npm i html-encrypt
```
## Execute
```bash
npx html-encrypt
```
Note: running the command will modify the file.
## Options
- You will be asked to enter the Password
Please consider using a safe password
- Additionally, you can bring in your own template. Create a .html file and reference it when asked in the CLI.
```html
PW:
Login
```
- You can also set the password with -p
```bash
npx html-encrypt --remove-head -p
```
- You can also add --remove-head in order to remove the content of the head for the output file. This might be needed for some SPAs.
```bash
npx html-encrypt --remove-head
```
- You can also add --no-minify in order to not use html-minifier-terser and esbuild.
```bash
npx html-encrypt --no-minify
```
- You can also skip the optional template path with --own-template. Or combine it with a secure -p in a Pipeline.
```bash
npx html-encrypt --own-template
```