Last active
March 21, 2019 17:01
-
-
Save misterdev/2ef5042583c696055d207bb020fb7a14 to your computer and use it in GitHub Desktop.
9
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | |
<meta name="viewport" content="width=device-width,initial-scale=1.0"> | |
<link rel="icon" href="/favicon.ico"> | |
<title><%= title %></title> | |
</head> | |
<body> | |
<noscript> | |
<strong>We're sorry but <%= title %> doesn't work properly without JavaScript enabled. Please enable it to continue.</strong> | |
</noscript> | |
<div id="app"></div> | |
<!-- built files will be auto injected --> | |
</body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
writing() { | |
// => Writes webpack.config.json | |
this.config.set('configuration', this.options.env.configuration); | |
// => Write package.json, .eslintrc and .babelrc | |
this.fs.extendJSON(this.destinationPath('package.json'), createPackageJson(this.answers)); | |
/* ... */ | |
const { name, publicFolder } = this.answers; | |
// => Copies public/index.html in the destination folder replacing the title | |
this.fs.copyTpl( | |
this.templatePath('public/index.html'), | |
this.destinationPath(`${publicFolder}/index.html`), | |
{ title: name } | |
); | |
/* ... */ | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment