Skip to content

Commit 5b562e9

Browse files
ArbaazDossaniheyimalexMidnightDesigniansumrmckeb
authored
Feature/customized webpack plugin integration (#2)
* Fix CI issue on windows (facebook#7385) * Attempt at fixing CI issue on windows * Try to debug why verdaccio isn't in the ps output * Just remove the kill call alltogether * Update url-loader to 2.0.1 This closes facebook#7359 by making IMAGE_INLINE_SIZE_LIMIT=0 actually disable image inlining. We use url-loader's `limit` option to set the line at which images will be inlined, and we basically expose this option to our end users via the IMAGE_INLINE_SIZE_LIMIT environment variable. Most people using it want to disable inlining images all together (the major motivator for adding it at all was I think for strict CSP), and our documentation said setting the value to zero would do that. However, it did the opposite: url-loader treated zero as "no limit". The update to 2.x fixes this; zero means nothing gets inlined. The other changes from the version bump shouldn't affect us: - minimum node version is 8.9.x, we already require 8.10.x - the limit was "greater than", is now "greater than or equal to" * Docs: remove note about TypeScript files requiring at least one export (facebook#7260) * Add question issue template (facebook#7423) * Add question issue template * Fix bug report template formatting * Fix bug report template formatting * Add labels to pull request template * Update deploy instructions in contributing guide (facebook#7429) * Update deploy instructions in contributing guide * Update docs publishing instructions * Remove labels from pull request template * Add explicit check for --watchAll=false (facebook#7433) Resolves facebook#7180. * Add ESLint 6 support (facebook#7415) * Update testing-library package names in README (facebook#7340) * Update ESlint Install Docs (facebook#7451) * Improve bootstrap docs when using custom SCSS (facebook#7462) * Added dependencies to bootstrap article when using custom SCSS. * Make changes to package designation and added npm install directions. * Suggest `jsx: "react"` in tsconfig (facebook#7472) * Set jsonpFunction to prevent conflicts (facebook#5951) * Resolve relative paths for preprocessor styles (facebook#5829) preprocessor will output sourceMap by default then check if sourceMaps are needed on resolve-url-loader Fixes facebook#4653 * Specify roots in Jest config (facebook#7480) * Optimise templates for Lighthouse (facebook#7482) * Use readConfigFile instead of require for tsconfig (facebook#7248) * Fix HMR in Firefox when proxy option present (facebook#7444) Resolves facebook#6720 * Adjusted deployment documentation for ZEIT Now (facebook#7488) * Adjusted deployment documentation for ZEIT Now * Fixed missing word * Update docusaurus/docs/deployment.md Co-Authored-By: Joe Haddad <[email protected]> * Bump dependencies (facebook#7473) * Support configuring coveragePathIgnorePatterns (facebook#7080) * Fix RegExp from navigateFallbackBlacklist (workbox) (facebook#7176) Exclude URLs that contains a "?" character. * Fix launch.json debugging config (facebook#6484) * Add vscodium to the editor list (facebook#7028) * Bump version of sass-loader (facebook#7496) * Add readonly modifier for css module (facebook#7497) * Remove unused dependencies in babel-preset-react-app (facebook#5818) * Remove unused dependencies in babel-preset-react-app * Re-add @babel/plugin-transform-react-display-name * Remove some dependencies again * Prepare 3.1.0 release * Publish - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] * Add links to Spectrum in README and docs (facebook#7500) * Update bug report issue template * Don't block static files in robots.txt (facebook#7508) * Ignore "jsx-a11y/aria-role" for React components (facebook#7393) * Update docusaurus config (facebook#7499) * Update Netlify config (facebook#7527) * Fix ESLint 6 support (facebook#7513) * Remove extends restriction to fix ESLint 6 support * Attempt to resolve CI errors * Prepare 3.1.1 release * Publish - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] * Show logo on mobile docs (facebook#7521) * Show logo for mobile views in create-react-app.dev * Update docusaurus/website/static/css/custom.css Co-authored-by: Sabesh Kumar Rajendran <[email protected]> * Add a migration step to remove static directory from robots.txt (facebook#7536) * add a migration step to remove static from robots.txt * Update CHANGELOG.md Co-Authored-By: Ian Sutherland <[email protected]> * docs: update Flow documentation (facebook#7550) * docs: update Flow documentation * Update adding-flow.md * Update adding-flow.md * Correct proxy usage docs (facebook#7368) * Remove trailing spaces from manifest.json (facebook#7585) * Link changelogs between major versions (facebook#7613) * Remove cleanup-after-each example (facebook#7620) cleanup is called now by default after each test if the testing framework supports the afterEach global * Adopt Contributor Covenant (facebook#7650) * Adopt Contributor Covenant * Add link to Contributor Covenant to docs site * Fix build (facebook#7662) * Disable babel-loader's cacheCompression (facebook#7633) * Update troubleshooting.md (facebook#7459) * Explicitly check that EXTEND_ESLINT is true (facebook#7538) * Update running-tests.md (facebook#7659) * Bump version of @typescript-eslint/* (facebook#7540) * Upgrade dotenv-expand to fix issues (facebook#7531) * Minor performance improvements (facebook#7587) - use ESLint cache - remove useless `watch` option in fork-ts-checker * Remove --single-quote from prettier examples (facebook#7663) * Use const instead of var in env.js (facebook#7526) * Change runtime chunk name separator from tilde to dash (facebook#7679) * Bump dependencies (facebook#7681) * Update deployment.md with another AWS example (facebook#7616) Add blog post that takes a React developer step-by-step through many features of AWS. Blog post is suitable for a beginner to follow and have a production ready workflow. * Add new logo (facebook#7704) * Prepare 3.1.2 release * Publish - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] * Update runtime chunk name separator in docs (facebook#7705) * Remove 'shortcut' link type before 'icon' (facebook#7707) * Guard polyfills against window possibly being undefined (facebook#7205) * Enable .eslintignore with extend flag (facebook#7562) * Add "entrypoints" key to asset manifest (facebook#7721) * Update adding flow documentation (facebook#7731) * set output.globalObject to 'this' (facebook#7742) Closes facebook#7741 * Update logic and log errors for EXTEND_ESLINT (facebook#7530) * update list of supported jest config overrides (facebook#7601) * Upgrade Webpack version (facebook#7740) * Close br tags in template README files (facebook#7668) * Fix variable name casing in fileTransform (facebook#7752) * Documentation typo fix (facebook#7757) * Fix linting error when using rest props (facebook#7754) * Add TSC_COMPILE_ON_ERROR setting (facebook#6931) * Remove switch case (facebook#7729) * docs: note that v2 to v3 migration may require deletion of node_modules (facebook#7302) * Stop hiding the column number of ESLint errors (facebook#6980) * Support setting baseUrl to root directory (facebook#7755) * Use installing package manager in README (facebook#7687) * Support production profiling with React Developer Tools (facebook#7737) * Added the alias for profiling and output change to keep the classNames and functionNames for human readbility * defined isEnvProductionProfile with other isEnv checks * moved the keep_classnames and keep_fnames to terserOptions scope * resolve merge conflict for yarn.lock.cache * revert yarn.lock.cache to master yarn.lock.cache - git checkout origin/master -- packages/create-react-app/yarn.lock.cached * Comment and Boolean Check - I clarified the comment and specified the use case - Changed the environment check to check for the specific true rather than the assumed primitive value as before. * Replaced env with flag - Per suggestion --profile flag used instead of env variable PROFILE_APP * documentation in available scripts section with suggested information * resolved a local git issue. Fixed documentation error. * moved documentation to suggested file - Added a brief summary of profiling in available scripts section. The summary references the production-build document. Which is the file I moved the new documentation into under a new Header for production support. * Update production-build.md Co-authored-by: Ian Sutherland <[email protected]> * Prepare 3.2.0 release * Publish - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] * Temporarily disable Windows in CI (facebook#7773) * Add babel runtime version to transform-runtime plugin to reduce… (facebook#7726) * Add Babel sourcemap to resolve VSCode debugging issues (facebook#7022) * Fix process type in TypeScript template (facebook#7796) * Account for browserslist environment variables (facebook#7764) * Clarify dynamic import stage in docs (facebook#7813) * Update adding-typescript.md (facebook#7815) * Document how to use the .env file to enforce HTTPS (facebook#7821) * Fix absolute paths issue in Jest (facebook#7822) * Document correct default behavior for HOST var (facebook#7823) * Fix grammar error in troubleshooting.md (facebook#7824) * Upgrade to docusaurus 2 (facebook#7785) * chore: upgrade to docusaurus 2 * address review * Update doc publishing instructions * Revert logo in templates (facebook#7830) * feat: add additional Jest keys to whitelist (facebook#7832) * Link to React documentation for code splitting (facebook#7686) The official documentation offers a simpler way of achieving route based code splitting. * Add a note about .eslingignore files being respected (facebook#7809) * added check for typescript template and unsupported node version (facebook#7839) * added check for typescript template and unsupported node version * addressed code review feedback regarding syntax and spelling mistakes * Update getting-started.md (facebook#7841) Update the initial project structure generated by create-react-app. * Link to ASP.NET Core docs (facebook#7840) * Update readme gif links (facebook#7849) * Update adding-bootstrap.md (facebook#7853) typo fix * Move unused eslint webpack import into @remove-on-eject block (facebook#7856) * 📖 DOC: Improvement (facebook#7819) * Upgrade terser & enable parallel minification in wsl (facebook#7857) * Add a GitHub Action that runs the build script (facebook#7861) * Edit InterpolateHtmlPlugin hook (facebook#6448) (facebook#6449) * Fix notations of loopback addresses (facebook#7474) * Add Service-Worker header to checkValidServiceWorker (facebook#6753) * Add header to checkValidServiceWorker (ts) * Add header to checkValidServiceWorker * Add additional information for postcss errors (facebook#6282) (facebook#6352) * Add additional information for postcss errors * Add additional information for postcss errors (simplify) * Remove chunkname from postCSS compile error * Remove line number from postCSS compile error * Fix eslint complaints in build.js (facebook#7870) * Add Alex to lint documentation (facebook#7852) * Add Alex to lint documentation * Attempt to trigger GitHub Action * Configure Alex and update docs * More docs updates * Bump docusaurus 🦖 (facebook#7874) * Dark scheme overlay (facebook#7052) * Bump react (facebook#7875) * Bump styling related loaders (facebook#7876) * Remove alex precommit check (facebook#7878) * Add template support (facebook#7716) * Add template support * Update templates version check * Update TypeScript template README * Prepare 3.3.0 beta * If template name already starts with cra-template leave it alone (facebook#7880) * Update prerelease publishing instructions * Upgrade packages and tweak config to adapt to new config format (facebook#7814) Rebased again now with smaller changes in this one which will make it easier to revert in case of eventual regressions. * refactor: remove double coerce (facebook#7882) * Add yarn.lock to .gitignore (facebook#7789) * chore: Fix broken link for CRA deployment (facebook#7897) * chore: Fix broken link for e2e README (facebook#7896) * Add @testing-library to the default templates (facebook#7881) * Add numeric separator support (facebook#7817) * Update open (facebook#7910) * Mark TypeScript as an optional peer dependency (facebook#7860) * Add restoreMocks to supported jest config keys (facebook#7921) * fix seperators typo (facebook#7932) Its the little things that makes the big difference! 😁 Thanks * No spinning React logo if `prefers-reduced-motion` (facebook#7931) * Made PRs welcome badge point to contributors guide (facebook#7792) * Make JavaScript and TypeScript templates consistent (facebook#7944) * Fix CI (facebook#7951) * Add optional chaining and nullish coalescing operators support (facebook#7438) * Add tests for optional chaining and null coalescing (facebook#7952) * Upgrade jest-watch-typeahead (facebook#7956) * Fix light background in docusaurus night mode (facebook#7936) * Fix light background in docusaurus night mode Closes facebook#7930 * Rename lightBackground to gettingStartedSection * Add placeholders where old template READMEs used to be (facebook#7972) * Temporarily disable GitHub Actions (facebook#7978) * Prepare 3.3.0 beta * Bump dependencies (facebook#7986) * Support scoped templates (facebook#7991) * Add contributors section to readme (facebook#7995) * added e2e test for checking typescript template with unsupported node (facebook#7844) * Unpin dependencies in react-app-polyfill (facebook#7999) * Add scripts support to templates (facebook#7989) * Override no-unused-expressions with the typescript-eslint version (facebook#8003) Fixes issues with optional chaining * Prefix apple-touch-icon links with PUBLIC_URL. (facebook#8005) * Bump webpack-dev-server (facebook#7988) * Bump dependencies (facebook#8024) * Re-enable GitHub Actions (facebook#8029) * Update CHANGELOG * Update CODEOWNERS * Remove no-unexpected-multiline rule (facebook#8039) * Add TypeScript peer dependency to react-scripts (facebook#8038) * Update template docs (facebook#8050) * Update template docs * Update custom-templates.md * Update custom-templates.md Co-authored-by: Ian Sutherland <[email protected]> * Prepare 3.3.0 release * Update CHANGELOG * Publish - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] * webpackHotDev now uses wss when https is used (facebook#8079) * Add custom-templates to docs sidebar (facebook#8077) * Fix typo in CHANGELOG.md (facebook#8080) * Remove error for @typescript-eslint/no-namespace (facebook#7803) Declare namespaces are supported by babel now, and babel will throw with a nice error message for non-declare namespaces, so this rule is unnecessary. Closes facebook#7651. * Fix CI build (facebook#8122) * Fix CSS font-face minification (facebook#8106) * Add slashes to WebSocket protocol URL (facebook#8116) * Fix typo in comment: `?.` is right, not `.?` (facebook#8124) This is just a comment fix. Actual optional chaining operator syntax is `?.`, not `.?`. * chore: update docusaurus & tweak site (facebook#8111) * [Security] Update terser webpack plugin (facebook#8102) * security: update terser webpack plugin * Add current version and bin location to --info output (facebook#8168) Make the --info subcommand outuput the current version information and the location of the file being run. Our issue template tells users to provide the output of --info, so having the current version is incredibly helpful, especially since it doesn't necessarily match the globally installed version that envinfo outputs. Knowing the location helps us determine whether the running bin is globally installed or in the local node_modules. * Bump pkgUp (facebook#8163) * Bump chalk (facebook#8164) * Add link to Netlify in README * Bump internal dependencies (facebook#8176) * Bump dependencies in react-dev-utils * Bump dependencies in react-app-polyfill * Bump dependencies in create-react-app * Bump dependencies in react-error-overlay * Bump dependencies in react-scripts * Bump react * Add package-runner note to readme (facebook#8132) * Add package-runner note to readme * Add link to `yarn create` * Update PWA docs links to point to template package (facebook#8147) * Minor refactors in create-react-app (facebook#8178) - Remove templates version minimum stopgap. - Replace indexOf with more idiomatic alternatives. - Inline errorLogFilePatterns. - Alphabetize validFiles. - Simplify log file removal code. - Move unconditional console.log() call outside of isSafe. - Differentiate conflicting directories from files. - Document yarn version special case. - Inline printValidationResults. - Standardize checkAppName output on failure. - Add link for checkThatNpmCanReadCwd. Functionally the code should be exactly the same. * fix: proactively append to .gitignore during init (facebook#8028) * Bump babel-plugin-tester and fix breaking changes (facebook#8171) * Little typo (facebook#8212) * Replace favicon in templates (facebook#8194) The old favicon was the same as the official react documentation, which is a minor annoyance during development when trying to find the tab you want. The new favicon is just the old with inverted colors. Closes facebook#7957 * Support shorthand scoped templates (facebook#8298) * Allow additional package keys and add blacklist (facebook#8082) (facebook#8219) * Minor grammatical edit (facebook#8293) * Update Dependencies (facebook#8324) * Remove React.FC from Typescript template (facebook#8177) This removes `React.FC` from the base template for a Typescript project. Long explanation for a small change: `React.FC` is unnecessary: it provides next to no benefits and has a few downsides. (See below.) I see a lot of beginners to TS+React using it, however, and I think that it's usage in this template is a contributing factor to that, as the prominence of this template makes it a de facto source of "best practice". ### Downsides to React.FC/React.FunctionComponent ##### Provides an implicit definition of `children` Defining a component with `React.FC` causes it to implicitly take `children` (of type `ReactNode`). It means that all components accept children, even if they're not supposed to, allowing code like: ```ts const App: React.FC = () => { /*... */ }; const Example = () => { <App><div>Unwanted children</div></App> } ``` This isn't a run-time error, but it is a mistake and one that would be caught by Typescript if not for `React.FC`. ##### Doesn't support generics. I can define a generic component like: ```ts type GenericComponentProps<T> = { prop: T callback: (t: T) => void } const GenericComponent = <T>(props: GenericComponentProps<T>) => {/*...*/} ``` But it's not possible when using `React.FC` - there's no way to preserve the unresolved generic `T` in the type returned by `React.FC`. ```ts const GenericComponent: React.FC</* ??? */> = <T>(props: GenericComponentProps<T>) => {/*...*/} ``` ##### Makes "component as namespace pattern" more awkward. It's a somewhat popular pattern to use a component as a namespace for related components (usually children): ```jsx <Select> <Select.Item /> </Select> ``` This is possible, but awkward, with `React.FC`: ```tsx const Select: React.FC<SelectProps> & { Item: React.FC<ItemProps> } = (props) => {/* ... */ } Select.Item = (props) => { /*...*/ } ``` but "just works" without `React.FC`: ```tsx const Select = (props: SelectProps) => {/* ... */} Select.Item = (props) => { /*...*/ } ``` ##### Doesn't work correctly with defaultProps This is a fairly moot point as in both cases it's probably better to use ES6 default arguments, but... ```tsx type ComponentProps = { name: string; } const Component = ({ name }: ComponentProps) => (<div> {name.toUpperCase()} /* Safe since name is required */ </div>); Component.defaultProps = { name: "John" }; const Example = () => (<Component />) /* Safe to omit since name has a default value */ ``` This compiles correctly. Any approach with `React.FC` will be slightly wrong: either `React.FC<{name: string}>` will make the prop required by consumers, when it should be optional, or `React.FC<{name?: string}>` will cause `name.toUpperCase()` to be a type error. There's no way to replicate the "internally required, externally optional" behavior which is desired. ##### It's as long, or longer than the alternative: (especially longer if you use `FunctionalComponent`): Not a huge point, but it isn't even shorter to use `React.FC` ```ts const C1: React.FC<CProps> = (props) => { } const C2 = (props: CProps) => {}; ``` ### Benefits of React.FC ##### Provides an explicit return type The only benefit I really see to `React.FC` (unless you think that implicit `children` is a good thing) is that it specifies the return type, which catches mistakes like: ```ts const Component = () => { return undefined; // components aren't allowed to return undefined, just `null` } ``` In practice, I think this is fine, as it'll be caught as soon as you try to use it: ```ts const Example = () => <Component />; // Error here, due to Component returning the wrong thing ``` But even with explicit type annotations, `React.FC` still isn't saving very much boilerplate: ```ts const Component1 = (props: ComponentProps): ReactNode => { /*...*/ } const Component2: FC<ComponentProps> = (props) => { /*...*/ } ``` * Downgrade open from 7.0.0 to 6.4.0 (facebook#8364) * Remove outdated babel plugins (facebook#8353) Updates dependencies and removes babel plugins that are now covered by `@babel/preset-env`. Co-authored-by: hdineen <[email protected]> * Add titleProp to SVGR ReactComponent type definition (facebook#8099) * Sync dependencies babel config (facebook#8120) * Update custom template docs with instructions for testing custom template locally (facebook#8092) Co-authored-by: Ian Schmitz <[email protected]> * Update setting-up-your-editor.md (facebook#8247) `Auto Fix is enabled by default. Use the single string form.` warning is shown in `.vscode/settings.json` due to changes in vscode-eslint. As autoFix is set to default, object format in `eslint.validate` is deprecated. * Remove outdated docs regarding vscode eslint extension and type… (facebook#8307) Co-authored-by: Ian Schmitz <[email protected]> * Fix sass importLoaders (facebook#8281) * Add "Disallow:" to robots.txt (facebook#8255) * Add helpful message to the footer (facebook#6548) * Update docs according to lint-staged v10 (facebook#8394) * docs: Add troubleshooting documentation on ENOSPC (facebook#8380) Co-authored-by: Ian Schmitz <[email protected]> * Prepare 3.3.1 release * Publish - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] * Make the PWA link point to the right place (facebook#8379) * Update commit message to use imperative mood (facebook#8377) Why: * As per best practice: https://git.kernel.org/pub/scm/git/git.git/tree/Documentation/SubmittingPatches#n135 See also: https://chris.beams.io/posts/git-commit/#imperative * Wider Chromium support for openBrowser (facebook#8367) * Expands scope of openBrowser tab control Adjust openChrome.applescript to allow manipulation of other Chromium-based browsers (defaulting to Chrome). Requires list of compatible browsers to try in openBrowser.js * Fix typo * Remove Safari * fix(test): force install npm in e2e-behaviour (facebook#8402) This will fix e2e-behaviour on macos Related: npm/cli#611 (comment) * setupTestFrameworkScriptFile is deprecated (facebook#8390) * setupTestFrameworkScriptFile is deprecated __Note:_ `_setupTestFrameworkScriptFile_` _is deprecated in favor of_ `_setupFilesAfterEnv_`_.__ ref: https://jestjs.io/docs/en/configuration#setupfilesafterenv-array * Update docusaurus/docs/running-tests.md Co-Authored-By: Simen Bekkhus <[email protected]> Co-authored-by: Simen Bekkhus <[email protected]> * Fix robots.txt for TS (facebook#8403) * Update public folder usage docs to clarify globals (facebook#8299) Added the relevant topic linked directly, instead of saying it's just in the next section. Adjusted the text so it sounds more like a recommendation rather than a requirement. The topic linked is basically explainer to how you'd reference it using the global window object and ways to avoid linter errors. Thus I used 'reference' to give users a hint of what it the linked page would be for. * Run git init before template dependencies are installed (facebook#8282) * Support JetBrains Rider IDE as an editor (facebook#7948) Rider is JetBrains .NET IDE, which supports the React plugin identically to other JetBrains IDEs such as Idea and WebStorm. * Enable custom sockjs pathname for hot reloading server. (facebook#7750) * Enable custom sockjs pathname for hot reloading server. * Update docusaurus/docs/advanced-configuration.md Co-Authored-By: Brody McKee <[email protected]> * let WDS_SOCKET_PATH be undefined * adding env variables for sockHost and sockPort options Co-authored-by: Brody McKee <[email protected]> * Add option to provide custom ssl certificates during development (facebook#5845) * Add option to provide custom SSL certificates when using HTTPS * Update documentation with custom HTTPS certs * Improve certificate validation and move to its own file * Update https in development docs Co-Authored-By: Brody McKee <[email protected]> * Add custom cert example to docs * Rename https file and update error message * Include original error message when custom ssl cert is invalid * Add chalk to react-scripts dependencies * Bump docs version to say that the new config will be available in 3.2.0 * Remove chalk dependency * Update custom ssl version to 3.4.0 in docs * Remove version from custom ssl certificate docs Co-authored-by: Brody McKee <[email protected]> * Handle service worker error in Firefox (facebook#8272) * Handle service worker error in Firefox See https://bugzilla.mozilla.org/show_bug.cgi?id=1429714 for more details. * Update serviceWorker.js * feat(react-scripts): allow PUBLIC_URL in develoment mode (facebook#7259) Co-authored-by: Eric Clemmons <[email protected]> Co-authored-by: Alex Guerra <[email protected]> Co-authored-by: Kelly <[email protected]> Co-authored-by: Eric Clemmons <[email protected]> Co-authored-by: Alex Guerra <[email protected]> Co-authored-by: Kelly <[email protected]> * Change arrow functions to function declarations (facebook#8412) - The JavaScript template uses a function declaration to define the component, the TypeScript template and a page of the documentation used arrow functions. Changed it to use function declarations for consistency and readability. * Fix navbar line break in header (facebook#8437) * Fixes unchecked access to 'deploy' script on build (facebook#8292) * Downgrade chalk for ie 11 support (facebook#8439) * Downgrade chalk for ie 11 support * Update lockfile * fix(react-scripts): do not redirect served path if request may proxy (facebook#8442) Moved redirect middleware and noopSW middleware in WDS after hook So proxy, and before proxy will take precedence before redirect Closes facebook#8417 * fix(typescriptFormatter): use chalk@2 constructor (facebook#8450) Related facebook#8164 Related facebook#8439 * update open to v7.0.2 (facebook#8459) * Correct webpack name casing (facebook#8475) webpack should always be written in lower-case, according to webpack's branding guidelines https://webpack.js.org/branding * Downgrade style-loader to v0.23.1 due to CSS modules hot reload… (facebook#8378) * Prepare 3.4.0 release * Publish - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] * Bump pnp-webpack-plugin (facebook#8509) * Closes webpack dev server and exits process on "end" stdin (facebook#7203) Co-authored-by: Ian Schmitz <[email protected]> * Widen eslint-config-react-app peer dependency versions (facebook#7790) Co-authored-by: Ian Schmitz <[email protected]> * Fix optional chaining and nullish coalescing support (facebook#8526) * Update template example in docs (facebook#8561) * Whitelist main in template.json (facebook#8539) * Use native ESLint behaviour when extending (facebook#8276) * Fix proxying API request docs (facebook#8515) The http-proxy-middleware package has made a major version upgraded and introduced a breaking change. This fixes the "Configuring the Proxy Manually" documentation to match the latest version. * Bump dependencies (facebook#8620) * Add React.StrictMode to default templates (facebook#8558) Co-authored-by: Dan Abramov <[email protected]> * Update to Babel 7.9 (facebook#8681) * Prepare 3.4.1 release * Publish - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] - [email protected] * Update template tests (facebook#8705) * Bump TypeScript template to 3.8 (facebook#8713) * Remove Unnecessary files Co-authored-by: Alex Guerra <[email protected]> Co-authored-by: Rudolph Gottesheim <[email protected]> Co-authored-by: Ian Sutherland <[email protected]> Co-authored-by: Brody McKee <[email protected]> Co-authored-by: Balázs Orbán <[email protected]> Co-authored-by: Chuck <[email protected]> Co-authored-by: Darius Tall <[email protected]> Co-authored-by: Sibiraj <[email protected]> Co-authored-by: Andrew Luca <[email protected]> Co-authored-by: Igor Muchychka <[email protected]> Co-authored-by: dominic scanlan <[email protected]> Co-authored-by: Jack Cross <[email protected]> Co-authored-by: Dmitry Lepskiy <[email protected]> Co-authored-by: Leo Lamprecht <[email protected]> Co-authored-by: Joe Haddad <[email protected]> Co-authored-by: Ian Schmitz <[email protected]> Co-authored-by: Kent C. Dodds <[email protected]> Co-authored-by: Andrea Puddu <[email protected]> Co-authored-by: Ryan Marsh <[email protected]> Co-authored-by: Leonardo Dino <[email protected]> Co-authored-by: ZHAO Jinxiang <[email protected]> Co-authored-by: Tomáš Szabo <[email protected]> Co-authored-by: Sabesh Rajendran <[email protected]> Co-authored-by: Sabesh Kumar Rajendran <[email protected]> Co-authored-by: Jon Stevens <[email protected]> Co-authored-by: Federico Zivolo <[email protected]> Co-authored-by: szabi <[email protected]> Co-authored-by: Emil Pålsson <[email protected]> Co-authored-by: iHmD <[email protected]> Co-authored-by: Jerome Leclanche <[email protected]> Co-authored-by: Clément Prévost <[email protected]> Co-authored-by: Brock Wills <[email protected]> Co-authored-by: Weyert de Boer <[email protected]> Co-authored-by: pierreneter <[email protected]> Co-authored-by: Dominic Tobias <[email protected]> Co-authored-by: brlewis <[email protected]> Co-authored-by: Jannis Hell <[email protected]> Co-authored-by: Doug Ross <[email protected]> Co-authored-by: Andrew <[email protected]> Co-authored-by: Samuel Meuli <[email protected]> Co-authored-by: Lewis Llobera <[email protected]> Co-authored-by: Jake Moxey <[email protected]> Co-authored-by: Iguchi Tomokatsu <[email protected]> Co-authored-by: Samuel Meuli <[email protected]> Co-authored-by: Laurin Quast <[email protected]> Co-authored-by: neilbryson <[email protected]> Co-authored-by: Reece Dunham <[email protected]> Co-authored-by: Rakan Nimer <[email protected]> Co-authored-by: Tomer Cohen <[email protected]> Co-authored-by: Alexandr Tovmach <[email protected]> Co-authored-by: Kyle Bebak <[email protected]> Co-authored-by: André Lins <[email protected]> Co-authored-by: Kim Persson <[email protected]> Co-authored-by: Justin Grant <[email protected]> Co-authored-by: Robert van Steen <[email protected]> Co-authored-by: Ashrith Reddy <[email protected]> Co-authored-by: Jacob M-G Evans <[email protected]> Co-authored-by: Damian Senn <[email protected]> Co-authored-by: Robert FUSZENECKER <[email protected]> Co-authored-by: Jonathan Felchlin <[email protected]> Co-authored-by: May <[email protected]> Co-authored-by: Orta <[email protected]> Co-authored-by: Tomáš Hübelbauer <[email protected]> Co-authored-by: Jesse Jackson <[email protected]> Co-authored-by: Jake Boone <[email protected]> Co-authored-by: Endi <[email protected]> Co-authored-by: Hugo David-Boyet <[email protected]> Co-authored-by: Sean Lafferty <[email protected]> Co-authored-by: Ali Waseem <[email protected]> Co-authored-by: reactjser <[email protected]> Co-authored-by: Daniel Lo Nigro <[email protected]> Co-authored-by: Chun <[email protected]> Co-authored-by: Xuhao <[email protected]> Co-authored-by: Sean Baines <[email protected]> Co-authored-by: Abdul Wahab ⚡️ <[email protected]> Co-authored-by: Guillaume Hertault <[email protected]> Co-authored-by: Wataru Ashihara <[email protected]> Co-authored-by: darthmaim <[email protected]> Co-authored-by: Joshua Robinson <[email protected]> Co-authored-by: Andreas Cederström <[email protected]> Co-authored-by: Fabiano Brito <[email protected]> Co-authored-by: Kanitkorn Sujautra <[email protected]> Co-authored-by: Havit Rovik <[email protected]> Co-authored-by: Kent C. Dodds <[email protected]> Co-authored-by: Tharun Rajendran <[email protected]> Co-authored-by: Dylan Staley <[email protected]> Co-authored-by: Donavon West <[email protected]> Co-authored-by: James George <[email protected]> Co-authored-by: RJ Morgan <[email protected]> Co-authored-by: Renato Augusto Gama dos Santos <[email protected]> Co-authored-by: Mateusz Burzyński <[email protected]> Co-authored-by: Klas Björkqvist <[email protected]> Co-authored-by: Ali Waseem <[email protected]> Co-authored-by: Max Davidson <[email protected]> Co-authored-by: Ben Blank <[email protected]> Co-authored-by: Mike Caulley <[email protected]> Co-authored-by: Trontor <[email protected]> Co-authored-by: Sean Zhu <[email protected]> Co-authored-by: Simon Donaldson <[email protected]> Co-authored-by: Wojciech Zieliński <[email protected]> Co-authored-by: Vadzim <[email protected]> Co-authored-by: Jerome De Leon <[email protected]> Co-authored-by: Peet Goddard <[email protected]> Co-authored-by: Brian Muenzenmeyer <[email protected]> Co-authored-by: Sony AK <[email protected]> Co-authored-by: Kai Hao <[email protected]> Co-authored-by: Tom Valorsa <[email protected]> Co-authored-by: Evan Grim <[email protected]> Co-authored-by: Retsam <[email protected]> Co-authored-by: Vincent Semrau <[email protected]> Co-authored-by: hdineen <[email protected]> Co-authored-by: Rasmus Nørskov <[email protected]> Co-authored-by: Kevin Old <[email protected]> Co-authored-by: Boyuan Xu <[email protected]> Co-authored-by: Alex James Vukovity <[email protected]> Co-authored-by: Marius Craciunoiu <[email protected]> Co-authored-by: Tomoya Fujita <[email protected]> Co-authored-by: Joshua Pollak <[email protected]> Co-authored-by: Hu Chen <[email protected]> Co-authored-by: Cassidy Williams <[email protected]> Co-authored-by: Christopher Button <[email protected]> Co-authored-by: Matthew Curtis <[email protected]> Co-authored-by: Andrew Luca <[email protected]> Co-authored-by: 吕立青 <[email protected]> Co-authored-by: Simen Bekkhus <[email protected]> Co-authored-by: Martin Litvaj <[email protected]> Co-authored-by: Kevin Pham <[email protected]> Co-authored-by: Łukasz Fiszer <[email protected]> Co-authored-by: David Powell <[email protected]> Co-authored-by: Grady Kuhnline <[email protected]> Co-authored-by: Alex Brazier <[email protected]> Co-authored-by: Rohit Singhal <[email protected]> Co-authored-by: Eric Clemmons <[email protected]> Co-authored-by: Kelly <[email protected]> Co-authored-by: Eugene Sviridov <[email protected]> Co-authored-by: Renato Böhler <[email protected]> Co-authored-by: Vincent Semrau <[email protected]> Co-authored-by: Eugene Chybisov <[email protected]> Co-authored-by: Maël Nison <[email protected]> Co-authored-by: Kelsey Leftwich <[email protected]> Co-authored-by: Vincent <[email protected]> Co-authored-by: Evan Boyle <[email protected]> Co-authored-by: Herman J. Radtke III <[email protected]> Co-authored-by: KatCon <[email protected]> Co-authored-by: Dan Abramov <[email protected]> Co-authored-by: Michaël De Boey <[email protected]> Co-authored-by: Braedon Gough <[email protected]>
1 parent 0b1d636 commit 5b562e9

File tree

472 files changed

+34857
-9109
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

472 files changed

+34857
-9109
lines changed

.alexignore

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
build
2+
3+
CHANGELOG*
4+
CODE_OF_CONDUCT.md

.alexrc

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"allow": [
3+
"attacks",
4+
"colors",
5+
"conservative",
6+
"crashes",
7+
"executed",
8+
"executes",
9+
"execution",
10+
"failed",
11+
"hook",
12+
"host-hostess",
13+
"hostesses-hosts",
14+
"invalid",
15+
"remain",
16+
"watchman-watchwoman"
17+
]
18+
}

.eslintignore

+1
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@ build
33
my-app*
44
packages/react-scripts/template
55
packages/react-scripts/fixtures
6+
fixtures/

.eslintrc .eslintrc.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"es6": true
88
},
99
"parserOptions": {
10-
"ecmaVersion": 6
10+
"ecmaVersion": 2018
1111
},
1212
"rules": {
1313
"no-console": "off",

.github/CODEOWNERS

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
packages/ @ianschmitz @iansu @mrmckeb @petetnt
2+
docusaurus/ @amyrlam @iansu

.github/ISSUE_TEMPLATE.md .github/ISSUE_TEMPLATE/bug_report.md

+56-55
Original file line numberDiff line numberDiff line change
@@ -1,96 +1,100 @@
1-
<!--
2-
PLEASE READ THE FIRST SECTION :-)
3-
-->
4-
5-
### Is this a bug report?
6-
7-
(write your answer here)
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
labels: 'issue: bug report, needs triage'
5+
---
86

97
<!--
10-
If you answered "Yes":
11-
128
Please note that your issue will be fixed much faster if you spend about
139
half an hour preparing it, including the exact reproduction steps and a demo.
14-
10+
1511
If you're in a hurry or don't feel confident, it's fine to report bugs with
1612
less details, but this makes it less likely they'll get fixed soon.
1713
18-
In either case, please fill as many fields below as you can.
19-
20-
If you answered "No":
14+
In either case, please use this template and fill in as many fields below as you can.
2115
22-
If this is a question or a discussion, you may delete this template and write in a free form.
2316
Note that we don't provide help for webpack questions after ejecting.
2417
You can find webpack docs at https://webpack.js.org/.
2518
-->
2619

20+
### Describe the bug
2721

28-
### Can you also reproduce the problem with npm 4.x?
22+
(Write your answer here.)
23+
24+
### Did you try recovering your dependencies?
2925

3026
<!--
31-
Many errors, especially related to "missing modules", are due to npm bugs.
32-
Which version of npm are you running? You can find out by checking:
27+
Your module tree might be corrupted, and that might be causing the issues.
28+
Let's try to recover it. First, delete these files and folders in your project:
3329
34-
npm -v
30+
* node_modules
31+
* package-lock.json
32+
* yarn.lock
3533
36-
If it is 5.x, please be aware that it has more than 50 known bugs, and
37-
is not guaranteed to work with Create React App.
34+
Then you need to decide which package manager you prefer to use.
35+
We support both npm (https://npmjs.com) and yarn (http://yarnpkg.com/).
36+
However, **they can't be used together in one project** so you need to pick one.
3837
39-
If it's not starting with 4, try to install npm 4.x:
38+
If you decided to use npm, run this in your project directory:
4039
41-
npm install -g npm@4
42-
cd your_project_directory
43-
rm -rf node_modules
44-
npm cache clear
40+
npm install -g npm@latest
4541
npm install
4642
47-
Then try to reproduce the issue again.
48-
Can you still reproduce it?
43+
This should fix your project.
44+
45+
If you decided to use yarn, update it first (https://yarnpkg.com/en/docs/install).
46+
Then run in your project directory:
47+
48+
yarn
49+
50+
This should fix your project.
51+
52+
Importantly, **if you decided to use yarn, you should never run `npm install` in the project**.
53+
For example, yarn users should run `yarn add <library>` instead of `npm install <library>`.
54+
Otherwise your project will break again.
4955
50-
Note: Please try this even if you are using Yarn so that we know whether it's a Yarn-only bug.
56+
Have you done all these steps and still see the issue?
57+
Please paste the output of `npm --version` and/or `yarn --version` to confirm.
5158
-->
5259

5360
(Write your answer here.)
5461

55-
5662
### Which terms did you search for in User Guide?
5763

5864
<!--
5965
There are a few common documented problems, such as watcher not detecting changes, or build failing.
6066
They are described in the Troubleshooting section of the User Guide:
6167
62-
https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#troubleshooting
68+
https://facebook.github.io/create-react-app/docs/troubleshooting
6369
6470
Please scan these few sections for common problems.
6571
Additionally, you can search the User Guide itself for something you're having issues with:
66-
67-
https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md
68-
72+
73+
https://facebook.github.io/create-react-app/
74+
6975
If you didn't find the solution, please share which words you searched for.
7076
This helps us improve documentation for future readers who might encounter the same problem.
7177
-->
7278

7379
(Write your answer here if relevant.)
7480

75-
7681
### Environment
7782

7883
<!--
79-
Please fill in all the relevant fields by running these commands in terminal.
80-
-->
84+
To help identify if a problem is specific to a platform, browser, or module version, information about your environment is required.
85+
This enables the maintainers quickly reproduce the issue and give feedback.
8186
82-
1. `node -v`:
83-
2. `npm -v`:
84-
3. `yarn --version` (if you use Yarn):
85-
4. `npm ls react-scripts` (if you haven’t ejected):
87+
Run the following command in your React app's folder in terminal.
88+
Note: The result is copied to your clipboard directly.
8689
87-
Then, specify:
90+
`npx create-react-app --info`
8891
89-
1. Operating system:
90-
2. Browser and version (if relevant):
92+
Paste the output of the command in the section below.
93+
-->
9194

95+
(paste the output of the command here.)
9296

93-
### Steps to Reproduce
97+
### Steps to reproduce
9498

9599
<!--
96100
How would you describe your issue to someone who doesn’t know you or your project?
@@ -99,12 +103,11 @@ Then, specify:
99103

100104
(Write your steps here:)
101105

102-
1.
103-
2.
104-
3.
106+
1.
107+
2.
108+
3.
105109

106-
107-
### Expected Behavior
110+
### Expected behavior
108111

109112
<!--
110113
How did you expect the tool to behave?
@@ -114,8 +117,7 @@ Then, specify:
114117

115118
(Write what you thought would happen.)
116119

117-
118-
### Actual Behavior
120+
### Actual behavior
119121

120122
<!--
121123
Did something go wrong?
@@ -125,8 +127,7 @@ Then, specify:
125127

126128
(Write what happened. Please add screenshots!)
127129

128-
129-
### Reproducible Demo
130+
### Reproducible demo
130131

131132
<!--
132133
If you can, please share a project that reproduces the issue.
@@ -148,11 +149,11 @@ Then, specify:
148149

149150
<!--
150151
What happens if you skip this step?
151-
152+
152153
We will try to help you, but in many cases it is impossible because crucial
153154
information is missing. In that case we'll tag an issue as having a low priority,
154155
and eventually close it if there is no clear direction.
155-
156+
156157
We still appreciate the report though, as eventually somebody else might
157158
create a reproducible example for it.
158159

.github/ISSUE_TEMPLATE/proposal.md

+39
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
---
2+
name: Proposal
3+
about: Suggest an idea for improving Create React App
4+
labels: 'issue: proposal, needs triage'
5+
---
6+
7+
### Is your proposal related to a problem?
8+
9+
<!--
10+
Provide a clear and concise description of what the problem is.
11+
For example, "I'm always frustrated when..."
12+
-->
13+
14+
(Write your answer here.)
15+
16+
### Describe the solution you'd like
17+
18+
<!--
19+
Provide a clear and concise description of what you want to happen.
20+
-->
21+
22+
(Describe your proposed solution here.)
23+
24+
### Describe alternatives you've considered
25+
26+
<!--
27+
Let us know about other solutions you've tried or researched.
28+
-->
29+
30+
(Write your answer here.)
31+
32+
### Additional context
33+
34+
<!--
35+
Is there anything else you can add about the proposal?
36+
You might want to link to related issues here, if you haven't already.
37+
-->
38+
39+
(Write your answer here.)

.github/ISSUE_TEMPLATE/question.md

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
name: Question
3+
about: Get help with Create React App
4+
labels: 'needs triage'
5+
---
6+
7+
If you have a general question about Create React App or about building an app with Create React App we encourage you to post on our Spectrum community instead of this issue tracker. The maintainers and other community members can provide help and answer your questions there: https://spectrum.chat/create-react-app
8+
9+
If you're looking for general information on using React, the React docs have a list of resources: https://reactjs.org/community/support.html
10+
11+
If you've discovered a bug or would like to propose a change please use one of the other issue templates.
12+
13+
Thanks!

.github/lock.yml

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Configuration for lock-threads - https://github.com/dessant/lock-threads
2+
3+
# Number of days of inactivity before a closed issue or pull request is locked
4+
daysUntilLock: 5
5+
6+
# Issues and pull requests with these labels will not be locked. Set to `[]` to disable
7+
exemptLabels: []
8+
9+
# Do not comment when locking
10+
setLockReason: false
11+
lockComment: false

.github/stale.yml

+61
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
# Configuration for probot-stale - https://github.com/probot/stale
2+
3+
# Number of days of inactivity before an Issue or Pull Request becomes stale
4+
daysUntilStale: 30
5+
6+
# Number of days of inactivity before a stale Issue or Pull Request is closed.
7+
# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale.
8+
daysUntilClose: 5
9+
10+
# Issues or Pull Requests with these labels will never be considered stale. Set to `[]` to disable
11+
exemptLabels:
12+
- "contributions: claimed"
13+
- "contributions: up for grabs!"
14+
- "good first issue"
15+
- "issue: announcement"
16+
- "issue: bug"
17+
- "issue: needs investigation"
18+
- "issue: proposal"
19+
- "tag: breaking change"
20+
- "tag: bug fix"
21+
- "tag: documentation"
22+
- "tag: enhancement"
23+
- "tag: internal"
24+
- "tag: new feature"
25+
- "tag: underlying tools"
26+
27+
# Set to true to ignore issues in a project (defaults to false)
28+
exemptProjects: true
29+
30+
# Set to true to ignore issues in a milestone (defaults to false)
31+
exemptMilestones: true
32+
33+
# Label to use when marking as stale
34+
staleLabel: stale
35+
36+
# Limit the number of actions per hour, from 1-30. Default is 30
37+
limitPerRun: 30
38+
39+
issues:
40+
# Comment to post when marking Issues as stale.
41+
markComment: >
42+
This issue has been automatically marked as stale because it has not had any
43+
recent activity. It will be closed in 5 days if no further activity occurs.
44+
45+
# Comment to post when closing a stale Issue.
46+
closeComment: >
47+
This issue has been automatically closed because it has not had any recent
48+
activity. If you have a question or comment, please open a new issue.
49+
50+
pulls:
51+
# Comment to post when marking Pull Request as stale.
52+
markComment: >
53+
This pull request has been automatically marked as stale because it has not
54+
had any recent activity. It will be closed in 5 days if no further activity
55+
occurs.
56+
57+
# Comment to post when closing a stale Pull Request.
58+
closeComment: >
59+
This pull request has been automatically closed because it has not had any
60+
recent activity. If you have a question or comment, please open a new
61+
issue. Thank you for your contribution!

.github/workflows/build.yml

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
name: Build
2+
3+
on: [push]
4+
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v1
10+
- name: Install
11+
run: yarn --no-progress --non-interactive --no-lockfile
12+
- name: Build
13+
run: yarn build

.github/workflows/lint.yml

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
name: Lint
2+
3+
on: [push]
4+
5+
jobs:
6+
lint:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v1
10+
- name: Install
11+
run: yarn --no-progress --non-interactive --no-lockfile
12+
- name: Alex
13+
run: yarn alex

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,5 @@ npm-debug.log*
1111
yarn-debug.log*
1212
yarn-error.log*
1313
/.changelog
14+
.npm/
15+
yarn.lock

0 commit comments

Comments
 (0)