-
Add local domain to
/etc/hosts
:127.0.0.1 my-project.dev
-
Install mkcert
-
Create certificate for this domain:
➜ mkcert my-project.dev Created a new certificate valid for the following names 📜 - "my-project.dev" The certificate is at "./my-project.dev.pem" and the key at "./my-project.dev-key.pem" ✅
-
Add HTTPS options to Webpack Dev Server config:
devServer: { host: 'my-project.dev', https: { key: './my-project.dev-key.pem', cert: './my-project.dev.pem', } },
-
-
Save tinovyatkin/e78d3d7f778fa7cfa93df36f0d462087 to your computer and use it in GitHub Desktop.
Running Webpack Dev Server with HTTPS on developer machine using MKCERT
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment