@yext/pages-buildtools
v2.1.8
Published
## For local development * Run `yarn link` within this repo, then run `yarn link "@yext/pages-buildtools"` within your pages repo and finish with a `yarn install`. Any code changes can be made locally to this repo and will be reflected on your current pa
Downloads
87
Maintainers
Keywords
Readme
pages-buildtools
For local development
- Run
yarn link
within this repo, then runyarn link "@yext/pages-buildtools"
within your pages repo and finish with ayarn install
. Any code changes can be made locally to this repo and will be reflected on your current pages repo. - To go back to the remote's version of the build tools run
yarn unlink
within this repo, thenyarn unlink "@yext/pages-buildtools"
within your pages repo, and runyarn install
to install the node_modules required by the build tools.
To deploy changes to NPM:
Production sites should be pinned to a NPM tag, not a specific branch or commit in this repo. Once you have merged your changes, increment the version number in this repo's package.json
and run the command npm publish
.
To update an existing repo to use node_modules webpack
Copy the following files from
$REPO/generator-ysp
's tip of master branch (https://gerrit.yext.com/plugins/gitiles/generator-ysp/+/refs/heads/master) to your pages repo:app/templates/.eslintrc.json
->src/.eslintrc.json
app/templates/_gruntfile.js
->src/Gruntfile.js
app/templates/variations/_default_/src/gruntTasks/compile.js
->src/gruntTasks/compile.js
app/templates/entries.js
->src/entries.js
- Note: you only need to update the
{ brandsPath }
require path from./webpack/config.brands
to@yext/pages-buildtools/webpack/config.brands.js
.
- Note: you only need to update the
app/templates/postinstall.js
->src/postinstall.js
app/templates/variations/_default_/src/gruntTasks/compile.js
->src/gruntTasks/compile.js
Update the following files:
src/package.json
- Dependencies to remove (you can run
yarn remove [dependency]
):handlebars-loader
,resolve-url-loader
,script-loader
,babel-loader
,body-parser
,clean-webpack-plugin
,css-loader
,express
,file-loader
,grunt-webpack
,imports-loader
,loader-utils
,optimize-css-assets-webpack-plugin
,postcss-loader
,sass-loader
,speed-measure-webpack-plugin
,style-loader
,ts-loader
,uglifyjs-webpack-plugin
,webpack
- Dev dependencies to add (run
yarn add -D [dependency]
):[email protected]
,[email protected]
,[email protected]
,[email protected]
,[email protected]
,[email protected]
,[email protected]
,[email protected]
,[email protected]
,[email protected]
,[email protected]
,[email protected]
,[email protected]
,@yext/pages-buildtools@yextconsulting/pages-buildtools#[hash/branch/tag]
- [hash/branch/tag] maps to the version of build tools you need.
- Dependencies to remove (you can run
Remove the following files from your Pages repo:
src/webpack
Sample PR: https://github.com/yext-pages/services.lowes.com.pagescdn.com/pull/36