Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
4afde94
Adding files necessary to build and deploy app in Electric Flow
gmdayley Feb 13, 2019
d262b57
Add new template for electric flow
gmdayley Feb 13, 2019
1a6880a
minor tweaking/cleaning up
joeycozza Feb 13, 2019
4072e9c
removing unused logging stuff
joeycozza Feb 15, 2019
40a7368
adding beta to the blueprint
joeycozza Feb 15, 2019
37913bf
Merge branch 'develop' into ec-build-deploy
joeycozza Feb 15, 2019
c471f42
Merge pull request #34 from fs-webdev/ec-build-deploy
joeycozza Feb 15, 2019
5a60c85
added eslint-config-frontier:recommended to the templates, as well as…
joeycozza Feb 19, 2019
cb6931c
fixing pre-commit stuff to work with our prettier rules
joeycozza Feb 19, 2019
1b2c107
trying to fix the prettier changes to a template file
joeycozza Feb 19, 2019
91a29e7
trying to fix the prettier changes to a template file
joeycozza Feb 19, 2019
ff43094
Merge pull request #37 from fs-webdev/eslint
joeycozza Feb 19, 2019
02b4858
1.4.4 version bump;
joeycozza Feb 19, 2019
9cd7a06
readme update
joeycozza Feb 19, 2019
ce9e386
Merge branch 'frontierMaster' into develop
joeycozza Feb 19, 2019
b25a3b6
Merge branch 'frontierMaster' into develop
joeycozza Feb 19, 2019
802605c
Merge branch 'frontierMaster' into develop
joeycozza Feb 20, 2019
64feead
adding eslint to tests, and removed react-router-dom from default dep…
joeycozza Feb 21, 2019
a53b58f
Edit webpack and webpack dev server configs to work with hf.
tylergraf Feb 21, 2019
3f31282
Conditionally add hf config
tylergraf Feb 21, 2019
fb4552e
Add comments in code.
tylergraf Feb 21, 2019
63cb39a
Merge pull request #39 from fs-webdev/addingLintToTests
joeycozza Feb 22, 2019
ef7000e
Merge branch 'develop' into hf
joeycozza Feb 22, 2019
79b51c2
Merge pull request #40 from fs-webdev/hf
tylergraf Feb 22, 2019
d3a3049
moving npmrc stuff for travis to handle
joeycozza Feb 22, 2019
38c8f7b
Merge pull request #41 from fs-webdev/updatingTravisEnvVar
joeycozza Feb 22, 2019
9037c56
Add template files for hf.
tylergraf Feb 22, 2019
39ded8e
Merge pull request #42 from fs-webdev/hf
joeycozza Feb 22, 2019
bdc7d86
minor fixes, and auto setup of .env file for hf template
joeycozza Feb 22, 2019
3b8dc39
removing console.logs
joeycozza Feb 22, 2019
ab9445f
keeping the default .env in case the hf option isnt selected
joeycozza Feb 22, 2019
a5af82e
changing function name
joeycozza Feb 22, 2019
ff9527e
removing the useYarn option from frontierInit code.
joeycozza Feb 22, 2019
cb0ab51
going to let `fr env` handle setting the SKIP_PREFLIGHT_CKECK=true
joeycozza Feb 22, 2019
ba7b1d0
removing .env file with the SKIP_PREFLIGHT_CHECK flag
joeycozza Feb 22, 2019
41aa1b6
only erroring on major version changes for certain dependencies
joeycozza Feb 22, 2019
063b609
Merge pull request #43 from fs-webdev/runFrEnvAutomatically
joeycozza Feb 22, 2019
b7775a7
Merge branch 'develop' into tweakingPreflightCheck
joeycozza Feb 22, 2019
3396392
Merge pull request #44 from fs-webdev/tweakingPreflightCheck
joeycozza Feb 22, 2019
cd3f18d
merge server.js files for ef and hf. Force ef in hf.
tylergraf Feb 22, 2019
5e6b573
Merge pull request #45 from fs-webdev/force-hf
joeycozza Feb 22, 2019
fb9f112
linting fixes, and speedup during install
joeycozza Feb 22, 2019
8629d3b
Merge branch 'develop' into lintingAndTweaksForRelease
joeycozza Feb 22, 2019
35fcc50
defering install to the end, renaming variable
joeycozza Feb 22, 2019
7a42449
fixing where the code said it was located on the landing page
joeycozza Feb 22, 2019
8853401
capitalization
joeycozza Feb 22, 2019
fb7a10f
Merge pull request #46 from fs-webdev/lintingAndTweaksForRelease
joeycozza Feb 22, 2019
a8a9889
1.6.0 react-scripts release
joeycozza Feb 22, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ node_js:
- 10
before_install:
- echo -e "machine github.com\n login $CI_USER_TOKEN" > ~/.netrc
- echo "//code.lds.org/artifactory/api/npm/npm-fhd/:_authToken=${NPM_PUBLISH_TOKEN}" >> ~/.npmrc
- echo "@fs:registry=https://code.lds.org/artifactory/api/npm/npm-fhd/" >> ~/.npmrc
install:
- "npm i"
- "cd packages/react-scripts"
Expand All @@ -13,7 +15,7 @@ deploy:
provider: npm
skip_cleanup: true
email: "dl-fh-eng-frontier@groups.ldschurch.org"
api_key: "$NPM_TOKEN"
api_key: "$NPM_PUBLISH_TOKEN"
on:
branch: frontierMaster
# This tells travis to not build when the branch is master. This is important to have on our master
Expand Down
2 changes: 0 additions & 2 deletions packages/react-scripts/.npmrc

This file was deleted.

23 changes: 21 additions & 2 deletions packages/react-scripts/config/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ const getClientEnvironment = require('./env');
const ModuleNotFoundPlugin = require('react-dev-utils/ModuleNotFoundPlugin');
const ForkTsCheckerWebpackPlugin = require('fork-ts-checker-webpack-plugin-alt');
const typescriptFormatter = require('react-dev-utils/typescriptFormatter');
const CopyWebpackPlugin = require('copy-webpack-plugin');

// @remove-on-eject-begin
const getCacheIdentifier = require('react-dev-utils/getCacheIdentifier');
// @remove-on-eject-end
Expand All @@ -44,6 +46,9 @@ const shouldInlineRuntimeChunk = process.env.INLINE_RUNTIME_CHUNK !== 'false';
// Check if TypeScript is setup
const useTypeScript = fs.existsSync(paths.appTsConfig);

// FS - check if hf is installed in root node_modules
const isHF = fs.existsSync(path.join(paths.appNodeModules, 'hf/webpack.config.js'));

// style files regexes
const cssRegex = /\.css$/;
const cssModuleRegex = /\.module\.css$/;
Expand Down Expand Up @@ -237,12 +242,15 @@ module.exports = function(webpackEnv) {
// https://twitter.com/wSokra/status/969633336732905474
// https://medium.com/webpack/webpack-4-code-splitting-chunk-graph-and-the-splitchunks-optimization-be739a861366
splitChunks: {
chunks: 'all',
// FS - split chunks was causing issues for webpacked hf build, async fixes it so that it doesn't
// try to use the same chunks for async/non-async assets
chunks: isHF ? 'async' : 'all',
name: false,
},
// Keep the runtime chunk separated to enable long term caching
// https://twitter.com/wSokra/status/969679223278505985
runtimeChunk: true,
// FS - Turn off for hf since it causes issues with imports in hf js files.
runtimeChunk: !isHF,
},
resolve: {
// This allows you to set a fallback for where Webpack should look for modules.
Expand Down Expand Up @@ -512,12 +520,23 @@ module.exports = function(webpackEnv) {
],
},
plugins: [
// FS - copy over hf's webpack built files to /static/hf directory to be
// used by snow.
isHF &&
new CopyWebpackPlugin([
{
from: path.join(paths.appNodeModules, `hf/dist/${isEnvProduction ? 'prod' : 'dev'}`),
to: 'static/hf/[name].[ext]',
toType: 'template',
},
]),
// Generates an `index.html` file with the <script> injected.
new HtmlWebpackPlugin(
Object.assign(
{},
{
inject: true,
filename: isHF ? '_index.html' : 'index.html',
template: paths.appHtml,
},
isEnvProduction
Expand Down
9 changes: 7 additions & 2 deletions packages/react-scripts/config/webpackDevServer.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,13 @@ const noopServiceWorkerMiddleware = require('react-dev-utils/noopServiceWorkerMi
const ignoredFiles = require('react-dev-utils/ignoredFiles');
const paths = require('./paths');
const fs = require('fs');
const path = require('path');

const protocol = process.env.HTTPS === 'true' ? 'https' : 'http';
const host = process.env.HOST || '0.0.0.0';

const isHF = fs.existsSync(path.join(paths.appNodeModules, 'hf/webpack.config.js'));

module.exports = function(proxy, allowedHost) {
return {
// WebpackDevServer 2.4.3 introduced a security fix that prevents remote
Expand All @@ -36,8 +39,7 @@ module.exports = function(proxy, allowedHost) {
// So we will disable the host check normally, but enable it if you have
// specified the `proxy` setting. Finally, we let you override it if you
// really know what you're doing with a special environment variable.
disableHostCheck:
!proxy || process.env.DANGEROUSLY_DISABLE_HOST_CHECK === 'true',
disableHostCheck: !proxy || process.env.DANGEROUSLY_DISABLE_HOST_CHECK === 'true',
// Enable gzip compression of generated files.
compress: true,
// Silence WebpackDevServer's own logs since they're generally not useful.
Expand Down Expand Up @@ -108,5 +110,8 @@ module.exports = function(proxy, allowedHost) {
// https://github.com/facebook/create-react-app/issues/2272#issuecomment-302832432
app.use(noopServiceWorkerMiddleware());
},
// FS - write to disk so that snow can serve assets
// looking them up with the manifestMap provided by hf
writeToDisk: isHF,
};
};
Loading