Skip to content
GitLab
    • Explore Projects Groups Snippets
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • C create-react-app
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 1,547
    • Issues 1,547
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 417
    • Merge requests 417
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Meta
  • create-react-app
  • Merge requests
  • !6621

make compiler a const not a let

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Administrator requested to merge github/fork/Primajin/patch-1 into master 6 years ago
  • Overview 4
  • Commits 1
  • Pipelines 0
  • Changes 1

Created by: Primajin

compiler is not being reassigned, so we can use a const here.

I have ejected my app a long time ago and changed that to a const back then - it builds flawlessly multiple times a day.

Compare
  • master (base)

and
  • latest version
    f4fddf90
    1 commit, 2 years ago

1 file
+ 1
- 1

    Preferences

    File browser
    Compare changes
packages/react-scripts/scripts/build.js
+ 1
- 1
  • View file @ f4fddf90

  • Edit in single-file editor

  • Open in Web IDE


@@ -143,7 +143,7 @@ checkBrowsers(paths.appPath, isInteractive)
function build(previousFileSizes) {
console.log('Creating an optimized production build...');
let compiler = webpack(config);
const compiler = webpack(config);
return new Promise((resolve, reject) => {
compiler.run((err, stats) => {
let messages;
0 Assignees
None
Assign to
0 Reviewers
None
Request review from
Labels
2
CLA Signed tag: internal
2
CLA Signed tag: internal
    Assign labels
  • Manage project labels

Milestone
3.0
3.0
None
Time tracking
No estimate or time spent
Lock merge request
Unlocked
1
1 participant
Administrator
Reference: facebook/create-react-app!6621
Source branch: github/fork/Primajin/patch-1

Menu

Explore Projects Groups Snippets