react-app-rewired icon indicating copy to clipboard operation
react-app-rewired copied to clipboard

package version not found in Releases, and error in react-app-rewired/index.js:20

Open didmehh opened this issue 8 years ago • 9 comments

hey guys, i tried to found Releases, my package version was 1.5.1. and nothing found.

to deploy project, had some problems.

> react-app-rewired build

/www/project/node_modules/react-app-rewired/index.js:20
      : getLoader(rule.use || rule.oneOf || (Array.isArray(rule.loader) && rule.loader) || [], matcher);
                                                                                                       ^
SyntaxError: Unexpected token ;
    at exports.runInThisContext (vm.js:53:16)
    at Module._compile (module.js:511:25)
    at Object.Module._extensions..js (module.js:550:10)
    at Module.load (module.js:456:32)
    at tryModuleLoad (module.js:415:12)
    at Function.Module._load (module.js:407:3)
    at Module.require (module.js:466:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/www/project/node_modules/react-app-rewired/config-overrides.js:1:79)
    at Module._compile (module.js:541:32)

so, what happen, this?

didmehh avatar Apr 24 '18 06:04 didmehh

Same error here

wangyuesong avatar Apr 24 '18 07:04 wangyuesong

+1, At the moment I needed to stick to 1.5.0 to solve the problem.

sergi-io avatar Apr 24 '18 08:04 sergi-io

+1, here is my package.json:

    "dependencies": {
        "antd": "^3.4.3",
        "react": "^16.3.2",
        "react-dom": "^16.3.2",
        "react-scripts-ts": "2.15.1"
    },
    "devDependencies": {
        "@types/jest": "^22.2.3",
        "@types/node": "^9.6.6",
        "@types/react": "^16.3.12",
        "@types/react-dom": "^16.0.5",
        "react-app-rewired": "^1.5.1",
        "ts-import-plugin": "^1.4.4",
        "typescript": "^2.8.3"
    }

and 1.5.0 still can't solve my problem.

ifussa avatar Apr 24 '18 08:04 ifussa

I have the same problem.
: getLoader(rule.use || rule.oneOf || (Array.isArray(rule.loader) && rule.loader) || [], matcher); ^ SyntaxError: Unexpected token ; at createScript (vm.js:56:10) at Object.runInThisContext (vm.js:97:10) at Module._compile (module.js:542:28) at Object.Module._extensions..js (module.js:579:10) at Module.load (module.js:487:32) at tryModuleLoad (module.js:446:12) at Function.Module._load (module.js:438:3) at Module.require (module.js:497:17) at require (internal/module.js:20:19) at Object.<anonymous> (C:\Users\x1c\Desktop\patent\patent\client\node_modules\react-app-rewired\config-overrides.js:1:79)

Dan-0216 avatar Apr 24 '18 08:04 Dan-0216

Please remember to remove or update package-lock.json when downgrading to v1.5.0

sergi-io avatar Apr 24 '18 08:04 sergi-io

yep, down to 1.5.0 temporarily. i had open PR

didmehh avatar Apr 24 '18 08:04 didmehh

@ifussa "react-app-rewired": "1.5.0", remove ^.

didmehh avatar Apr 24 '18 08:04 didmehh

thanks! that's works

ifussa avatar Apr 24 '18 08:04 ifussa

1.5.2 is out and there's a release.

timarney avatar Apr 24 '18 10:04 timarney