@montagejs/issue-cert-plus
v0.0.4
Published
issue cert
Downloads
7
Readme
@montagejs/issue-cert-plus
Use mkcert
to generate https
certificate, and automatically add system credit, built-in cache system optimization.
Install
$ pnpm i @montagejs/issue-cert-plus
Usage
import Mkcert from '@montagejs/issue-cert-plus';
export default () => {
async function getConfig() {
const info = new Mkcert({ domainList: 'www.example.com' }).mkcert();
return {
mode: 'development',
devServer: {
server: {
type: 'https',
options: {
...info,
},
}
},
}
}
return getConfig();
}
Generate Files
.
📦User Home
┣ 📂.certPlusHome
┣ ┗ 📜.cert.json
┣ ┗ 📜key.pem
┣ ┗ 📜cert.pem
Demo
First Usage
When Add New Domain
new Mkcert({ domainList: 'www.example.com' }).mkcert();
When No New Domain
Related third-party libraries
Now, enjoy it~