Hi
When I run npm run production (Laravel mix)
I have problem
`error in ./node_modules/aos/dist/aos.js
Module build failed: ReferenceError: Unknown plugin "transform-object-assign" specified in "C:\OSPanel\domains\Staleks\node_modules\aos\.babelrc" at 0, attempted to resolve relative to "C:\OSPanel\domains\Staleks\node_modules\aos"
at C:\OSPanel\domains\Staleks\node_modules\babel-core\lib\transformation\file\options\option-manager.js:180:17
at Array.map (
at Function.normalisePlugins (C:\OSPanel\domains\Staleks\node_modules\babel-core\lib\transformation\file\options\option-manager.js:158:20)
at OptionManager.mergeOptions (C:\OSPanel\domains\Staleks\node_modules\babel-core\lib\transformation\file\options\option-manager.js:234:36)
at OptionManager.init (C:\OSPanel\domains\Staleks\node_modules\babel-core\lib\transformation\file\options\option-manager.js:368:12)
at File.initOptions (C:\OSPanel\domains\Staleks\node_modules\babel-core\lib\transformation\file\index.js:212:65)
at new File (C:\OSPanel\domains\Staleks\node_modules\babel-core\lib\transformation\file\index.js:135:24)
at Pipeline.transform (C:\OSPanel\domains\Staleks\node_modules\babel-core\lib\transformation\pipeline.js:46:16)
at transpile (C:\OSPanel\domains\Staleks\node_modules\babel-loader\lib\index.js:49:20)
at C:\OSPanel\domains\Staleks\node_modules\babel-loader\lib\fs-cache.js:118:18
at ReadFileContext.callback (C:\OSPanel\domains\Staleks\node_modules\babel-loader\lib\fs-cache.js:31:21)
at FSReqWrap.readFileAfterOpen [as oncomplete] (fs.js:437:13)`
And it is only on production compile. How I can fix it?
Hi,
rm -rf node_modules/aos/.babelrc
before building.
In fact, .babelrc (from aos) should be added to .npmignore and so never published on npm.
Cheers.
Fixed on next branch. Will be released in few days.
As of august 2018 problem persists.
+1
Can confirm this too.
Module build failed: ReferenceError: Unknown plugin "transform-object-assign" specified in "/buddy/******ENCRYPTED******/web/app/themes/******ENCRYPTED******/node_modules/aos/.babelrc" at 0, attempted to resolve relative to "/buddy/******ENCRYPTED******/web/app/themes/******ENCRYPTED******/node_modules/aos"
If someone's still looking for a solution here (like i was), just install the next release of aos instead of the current version :
npm install aos@next
Most helpful comment
Hi,
rm -rf node_modules/aos/.babelrc
before building.
In fact, .babelrc (from aos) should be added to .npmignore and so never published on npm.
Cheers.