Intended outcome:
When I'm running:
Inside our project Sulu CMS.
It errors with all files containing nullable object like:
handleChange = (value: Value, media: ?Media) => {
};
https://github.com/sulu/sulu/blob/b83b17d66493024af45664fde07a4b5e13196b9d/src/Sulu/Bundle/MediaBundle/Resources/js/containers/CKEditor5/plugins/InternalLinkPlugin/overlays/MediaInternalLinkTypeOverlay.js#L13
src/Sulu/Bundle/MediaBundle/Resources/js/containers/CKEditor5/plugins/InternalLinkPlugin/overlays/MediaInternalLinkTypeOverlay.js Transformation error (Unexpected token (13:41))
Actual outcome:
ERR /Users/el/Sulu/sulu-develop.localhost/vendor/sulu/sulu/src/Sulu/Bundle/MediaBundle/Resources/js/containers/CKEditor5/plugins/InternalLinkPlugin/overlays/MediaInternalLinkTypeOverlay.js Transformation error (Unexpected token (13:41))
SyntaxError: Unexpected token (13:41)
at Object._raise (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/parser/error.js:97:45)
at Object.raiseWithData (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/parser/error.js:92:17)
at Object.raise (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/parser/error.js:41:17)
at Object.unexpected (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/parser/util.js:140:16)
at Object.tsParseNonArrayType (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/plugins/typescript/index.js:866:18)
at Object.tsParseArrayTypeOrHigher (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/plugins/typescript/index.js:870:23)
at Object.parseConstituentType [as tsParseTypeOperatorOrHigher] (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/plugins/typescript/index.js:930:16)
at Object.tsParseUnionOrIntersectionType (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/plugins/typescript/index.js:940:18)
at Object.parseConstituentType [as tsParseIntersectionTypeOrHigher] (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/plugins/typescript/index.js:953:19)
at Object.tsParseUnionOrIntersectionType (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/plugins/typescript/index.js:940:18)
Results:
446 errors
0 unmodified
9095 skipped
30 ok
How to reproduce the issue:
Versions
As I when using npx it will use the latest mobx-undecorate version I think.
Intended outcome:
When I'm running:
Inside our project Sulu CMS.
It errors with all files containing nullable object like:
https://github.com/sulu/sulu/blob/b83b17d66493024af45664fde07a4b5e13196b9d/src/Sulu/Bundle/MediaBundle/Resources/js/containers/CKEditor5/plugins/InternalLinkPlugin/overlays/MediaInternalLinkTypeOverlay.js#L13
Actual outcome:
ERR /Users/el/Sulu/sulu-develop.localhost/vendor/sulu/sulu/src/Sulu/Bundle/MediaBundle/Resources/js/containers/CKEditor5/plugins/InternalLinkPlugin/overlays/MediaInternalLinkTypeOverlay.js Transformation error (Unexpected token (13:41)) SyntaxError: Unexpected token (13:41) at Object._raise (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/parser/error.js:97:45) at Object.raiseWithData (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/parser/error.js:92:17) at Object.raise (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/parser/error.js:41:17) at Object.unexpected (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/parser/util.js:140:16) at Object.tsParseNonArrayType (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/plugins/typescript/index.js:866:18) at Object.tsParseArrayTypeOrHigher (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/plugins/typescript/index.js:870:23) at Object.parseConstituentType [as tsParseTypeOperatorOrHigher] (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/plugins/typescript/index.js:930:16) at Object.tsParseUnionOrIntersectionType (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/plugins/typescript/index.js:940:18) at Object.parseConstituentType [as tsParseIntersectionTypeOrHigher] (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/plugins/typescript/index.js:953:19) at Object.tsParseUnionOrIntersectionType (/Users/el/.npm/_npx/1347/lib/node_modules/mobx-undecorate/node_modules/@babel/parser/src/plugins/typescript/index.js:940:18) Results: 446 errors 0 unmodified 9095 skipped 30 okHow to reproduce the issue:
Versions
As I when using
npxit will use the latestmobx-undecorateversion I think.