Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stylis-plugin-rtl + source-map-loader = breakage #33

Open
Bnaya opened this issue Dec 9, 2021 · 36 comments
Open

stylis-plugin-rtl + source-map-loader = breakage #33

Bnaya opened this issue Dec 9, 2021 · 36 comments

Comments

@Bnaya
Copy link

Bnaya commented Dec 9, 2021

The built source files and the sourcemaps of the library contains reference to the src/ directory:

{"version":3,"file":"stylis-rtl.js","sourceRoot":"","sources":["../src/stylis-rtl.ts"],"names":[]

But the actual src directory is not shipped with the package, thus ../src/stylis-rtl.ts does not exist.
When using source-map-loader ( as with create react app 5), the build fails as it can't file stylis-rtl.ts

Possible solutions:

  • Use inline source-maps
  • Don't generate source-maps
  • ship src as well
@ghost
Copy link

ghost commented Dec 18, 2021

I am getting the same warning as well as shown below:

WARNING in ./node_modules/stylis-plugin-rtl/dist/stylis-rtl.js
Module Warning (from ./node_modules/source-map-loader/dist/cjs.js):
Failed to parse source map from '...\node_modules\stylis-plugin-rtl\src\stylis-rtl.ts' file: Error: ENOENT: no such file or directory, open '...\node_modules\stylis-plugin-rtl\src\stylis-rtl.ts'
@ ./src/contexts/ThemeContext.js 9:0-42 22:18-27
@ ./src/index.js 13:0-63 17:61-81

@mortezasabihi
Copy link

@fadijabi I have the same problem 🥲

@hamidsaif70
Copy link

the same too

@chrisk8er
Copy link

same error here...

WARNING in ./node_modules/stylis-plugin-rtl/dist/stylis-rtl.js
Module Warning (from ./node_modules/source-map-loader/dist/cjs.js):
Failed to parse source map from '...node_modules/stylis-plugin-rtl/src/stylis-rtl.ts' file: Error: ENOENT: no such file or directory, open '../node_modules/stylis-plugin-rtl/src/stylis-rtl.ts'
 @ ./src/components/RtlLayout.tsx 4:0-42 22:48-57
 @ ./src/App.tsx 8:0-47 18:37-46
 @ ./src/index.tsx 15:0-24 22:39-42

@shineysood
Copy link

I also have same problem

@hadarhubara10
Copy link

the same too

@NicoSan20
Copy link

Same here

@or-yam
Copy link

or-yam commented Jan 31, 2022

Getting the same

@amirgholikhani
Copy link

I also have same problem

@goerlitz
Copy link

same here. I forked a repo and ran npm install and npm start and then got this error.
What can I do to get rid of it?

@gucollaco
Copy link

Was also having this issue. I know it's not the best solution, but I was able to avoid these errors/warnings by reverting to stylis-plugin-rtl v1.

@shadigaafar
Copy link

I have the same problem. Any Solutions?

@egbertn
Copy link

egbertn commented Feb 25, 2022

npm i [email protected]
solved for me...

@SaeedZhiany
Copy link

is there any update on this issue? could someone find a solution except downgrading to previous versions (v1 and v2.0.2 and ...)

@lordlpua
Copy link

lordlpua commented Jul 19, 2022

The same problem v.2.1.1

@perfeshnal
Copy link

perfeshnal commented Jul 28, 2022

I have same problem on v.2.1.1
Any Solutions?

@rhinck
Copy link

rhinck commented Aug 4, 2022

I have this error in my React project as well and would love to hear if anyone has the issue and has resolved it.

@mlotfy
Copy link

mlotfy commented Aug 22, 2022

I have the same problem, any update

@ahamdan-ow
Copy link

I am having the same problem since a long time, any updates please?

@wrappixel
Copy link

wrappixel commented Aug 31, 2022

you can try to solve this warning with below steps. for me its working

  1. create .env file on root
  2. add this line : GENERATE_SOURCEMAP=false

Thats it !! re-run the project.

@arshak-grigoryan
Copy link

I have same problem on v.2.1.1
Any Solutions?

@amirvokhidov
Copy link

I have the same problem, on v.2.1.1

@amirshnll
Copy link

firstly, remove or uninstall stylis-plugin-rtl with npm or yarn:

yarn remove stylis-plugin-rtl

npm uninstall stylis-plugin-rtl

secondly, install [email protected] with npm or yarn:

@bienvenuelisis
Copy link

firstly, remove or uninstall stylis-plugin-rtl with npm or yarn:

yarn remove stylis-plugin-rtl

npm uninstall stylis-plugin-rtl

secondly, install [email protected] with npm or yarn:

That works for me.

@perfeshnal
Copy link

perfeshnal commented Dec 1, 2022

firstly, remove or uninstall stylis-plugin-rtl with npm or yarn:

yarn remove stylis-plugin-rtl

npm uninstall stylis-plugin-rtl

secondly, install [email protected] with npm or yarn:

Maybe your solution will work
But I think going back to the old version is not a real solution
We still waiting ...

@hugrave
Copy link

hugrave commented Jan 13, 2023

I have the same issue here... Is there a scheduled solution in the roadmap?

@barrychapman
Copy link

It is because the .ts file is not supplied in dist or src. Placing it there manually will fix it

@hitendramalviya
Copy link

Seems this community is missing contributors, a year old issue is still open, and faced by many including me, I think they just need to publish the package without source map generated, would solve this problem for now.

@itayperry
Copy link

Is this the same issue as #35?

@itayperry
Copy link

itayperry commented Feb 27, 2023

Seems this community is missing contributors, a year old issue is still open, and faced by many including me, I think they just need to publish the package without source map generated, would solve this problem for now.

Yeah it seems the last commit was on Dec 15, 2021 :( @hitendramalviya

@magrinj
Copy link

magrinj commented Mar 7, 2023

If anyone want to fix it easily, you can use patch-package with this patch:
I generate this one removing the sourcemapping in the tsconfig.json.

diff --git a/node_modules/stylis-plugin-rtl/.DS_Store b/node_modules/stylis-plugin-rtl/.DS_Store
new file mode 100644
index 0000000..e69de29
diff --git a/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.d.ts b/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.d.ts
index e3efd93..ac86e86 100644
--- a/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.d.ts
+++ b/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.d.ts
@@ -1,5 +1,5 @@
 import { Middleware } from 'stylis';
-declare type MiddlewareParams = Parameters<Middleware>;
+type MiddlewareParams = Parameters<Middleware>;
 declare function stylisRTLPlugin(element: MiddlewareParams[0], index: MiddlewareParams[1], children: MiddlewareParams[2], callback: MiddlewareParams[3]): string | void;
 export default stylisRTLPlugin;
 //# sourceMappingURL=stylis-rtl.d.ts.map
\ No newline at end of file
diff --git a/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.d.ts.map b/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.d.ts.map
index 3edea57..e50c55a 100644
--- a/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.d.ts.map
+++ b/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"stylis-rtl.d.ts","sourceRoot":"","sources":["../../src/stylis-rtl.ts"],"names":[],"mappings":"AACA,OAAO,EAQL,UAAU,EAIX,MAAM,QAAQ,CAAC;AAEhB,aAAK,gBAAgB,GAAG,UAAU,CAAC,UAAU,CAAC,CAAC;AA4B/C,iBAAS,eAAe,CACtB,OAAO,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAC5B,KAAK,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAC1B,QAAQ,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAC7B,QAAQ,EAAE,gBAAgB,CAAC,CAAC,CAAC,GAC5B,MAAM,GAAG,IAAI,CAWf;AAMD,eAAe,eAAe,CAAC"}
\ No newline at end of file
+{"version":3,"file":"stylis-rtl.d.ts","sourceRoot":"","sources":["../../src/stylis-rtl.ts"],"names":[],"mappings":"AACA,OAAO,EAQL,UAAU,EAIX,MAAM,QAAQ,CAAC;AAEhB,KAAK,gBAAgB,GAAG,UAAU,CAAC,UAAU,CAAC,CAAC;AA4B/C,iBAAS,eAAe,CACtB,OAAO,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAC5B,KAAK,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAC1B,QAAQ,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAC7B,QAAQ,EAAE,gBAAgB,CAAC,CAAC,CAAC,GAC5B,MAAM,GAAG,IAAI,CAYf;AAMD,eAAe,eAAe,CAAC"}
\ No newline at end of file
diff --git a/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.js b/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.js
index 7eeb3d3..33b6846 100644
--- a/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.js
+++ b/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.js
@@ -37,4 +37,3 @@ function stylisRTLPlugin(element, index, children, callback) {
 // is unused
 Object.defineProperty(stylisRTLPlugin, 'name', { value: 'stylisRTLPlugin' });
 exports.default = stylisRTLPlugin;
-//# sourceMappingURL=stylis-rtl.js.map
\ No newline at end of file
diff --git a/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.js.map b/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.js.map
deleted file mode 100644
index 0af053c..0000000
--- a/node_modules/stylis-plugin-rtl/dist/cjs/stylis-rtl.js.map
+++ /dev/null
@@ -1 +0,0 @@
-{"version":3,"file":"stylis-rtl.js","sourceRoot":"","sources":["../../src/stylis-rtl.ts"],"names":[],"mappings":";;;;;AAAA,sDAAgC;AAChC,iCAYgB;AAIhB,SAAS,yBAAyB,CAChC,OAA4B,EAC5B,KAA0B,EAC1B,QAA6B;IAE7B,QAAQ,OAAO,CAAC,IAAI,EAAE;QACpB,KAAK,eAAM,CAAC;QACZ,KAAK,oBAAW,CAAC;QACjB,KAAK,gBAAO;YACV,OAAO,CAAC,OAAO,CAAC,MAAM,GAAG,OAAO,CAAC,MAAM,IAAI,OAAO,CAAC,KAAK,CAAC,CAAC;QAC5D,KAAK,gBAAO,CAAC,CAAC;YACZ,OAAO,CAAC,KAAK,GAAG,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC;YAEvF,IAAI,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE;gBACnC,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAC,UAAC,CAAC;oBACzB,IAAI,CAAC,CAAC,IAAI,KAAK,gBAAO;wBAAE,CAAC,CAAC,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC;gBAC/C,CAAC,CAAC,CAAC;aACJ;SACF;KACF;IAED,IAAM,kBAAkB,GAA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ts
index e3efd93..ac86e86 100644
--- a/node_modules/stylis-plugin-rtl/dist/stylis-rtl.d.ts
+++ b/node_modules/stylis-plugin-rtl/dist/stylis-rtl.d.ts
@@ -1,5 +1,5 @@
 import { Middleware } from 'stylis';
-declare type MiddlewareParams = Parameters<Middleware>;
+type MiddlewareParams = Parameters<Middleware>;
 declare function stylisRTLPlugin(element: MiddlewareParams[0], index: MiddlewareParams[1], children: MiddlewareParams[2], callback: MiddlewareParams[3]): string | void;
 export default stylisRTLPlugin;
 //# sourceMappingURL=stylis-rtl.d.ts.map
\ No newline at end of file
diff --git a/node_modules/stylis-plugin-rtl/dist/stylis-rtl.d.ts.map b/node_modules/stylis-plugin-rtl/dist/stylis-rtl.d.ts.map
index f091310..1d49d45 100644
--- a/node_modules/stylis-plugin-rtl/dist/stylis-rtl.d.ts.map
+++ b/node_modules/stylis-plugin-rtl/dist/stylis-rtl.d.ts.map
@@ -1 +1 @@
-{"version":3,"file":"stylis-rtl.d.ts","sourceRoot":"","sources":["../src/stylis-rtl.ts"],"names":[],"mappings":"AACA,OAAO,EAQL,UAAU,EAIX,MAAM,QAAQ,CAAC;AAEhB,aAAK,gBAAgB,GAAG,UAAU,CAAC,UAAU,CAAC,CAAC;AA4B/C,iBAAS,eAAe,CACtB,OAAO,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAC5B,KAAK,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAC1B,QAAQ,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAC7B,QAAQ,EAAE,gBAAgB,CAAC,CAAC,CAAC,GAC5B,MAAM,GAAG,IAAI,CAWf;AAMD,eAAe,eAAe,CAAC"}
\ No newline at end of file
+{"version":3,"file":"stylis-rtl.d.ts","sourceRoot":"","sources":["../src/stylis-rtl.ts"],"names":[],"mappings":"AACA,OAAO,EAQL,UAAU,EAIX,MAAM,QAAQ,CAAC;AAEhB,KAAK,gBAAgB,GAAG,UAAU,CAAC,UAAU,CAAC,CAAC;AA4B/C,iBAAS,eAAe,CACtB,OAAO,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAC5B,KAAK,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAC1B,QAAQ,EAAE,gBAAgB,CAAC,CAAC,CAAC,EAC7B,QAAQ,EAAE,gBAAgB,CAAC,CAAC,CAAC,GAC5B,MAAM,GAAG,IAAI,CAYf;AAMD,eAAe,eAAe,CAAC"}
\ No newline at end of file
diff --git a/node_modules/stylis-plugin-rtl/dist/stylis-rtl.js b/node_modules/stylis-plugin-rtl/dist/stylis-rtl.js
index 513e600..3e341c3 100644
--- a/node_modules/stylis-plugin-rtl/dist/stylis-rtl.js
+++ b/node_modules/stylis-plugin-rtl/dist/stylis-rtl.js
@@ -32,4 +32,3 @@ function stylisRTLPlugin(element, index, children, callback) {
 // is unused
 Object.defineProperty(stylisRTLPlugin, 'name', { value: 'stylisRTLPlugin' });
 export default stylisRTLPlugin;
-//# sourceMappingURL=stylis-rtl.js.map
\ No newline at end of file
diff --git a/node_modules/stylis-plugin-rtl/dist/stylis-rtl.js.map b/node_modules/stylis-plugin-rtl/dist/stylis-rtl.js.map
deleted file mode 100644
index e6561ca..0000000
--- a/node_modules/stylis-plugin-rtl/dist/stylis-rtl.js.map
+++ /dev/null
@@ -1 +0,0 @@
-{"version":3,"file":"stylis-rtl.js","sourceRoot":"","sources":["../src/stylis-rtl.ts"],"names":[],"mappings":"AAAA,OAAO,QAAQ,MAAM,UAAU,CAAC;AAChC,OAAO,EACL,OAAO,EACP,OAAO,EACP,WAAW,EACX,MAAM,EACN,OAAO,EACP,SAAS,EACT,MAAM,EAEN,SAAS,EACT,KAAK,EACL,QAAQ,GACT,MAAM,QAAQ,CAAC;AAIhB,SAAS,yBAAyB,CAChC,OAA4B,EAC5B,KAA0B,EAC1B,QAA6B;IAE7B,QAAQ,OAAO,CAAC,IAAI,EAAE;QACpB,KAAK,MAAM,CAAC;QACZ,KAAK,WAAW,CAAC;QACjB,KAAK,OAAO;YACV,OAAO,CAAC,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,IAAM,WAAW,GAAG,QAAQ,CAAC,SAAS,CAAC,yBAAyB,CAAC,OAAO,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC;QAC5F,OAAO,CAAC,QAAQ,GAAG,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,CAAC;QAEvE,OAAO,CAAC,MAAM,GAAG,EAAE,CAAC;KACrB;AACH,CAAC;AAED,qFAAqF;AACrF,YAAY;AACZ,MAAM,CAAC,cAAc,CAAC,eAAe,EAAE,MAAM,EAAE,EAAE,KAAK,EAAE,iBAAiB,EAAE,CAAC,CAAC;AAE7E,eAAe,eAAe,CAAC"}
\ No newline at end of file

@behradnasehi
Copy link

I have the same problem, on v.2.1.1

@farhadibehnamdev
Copy link

Installing v2.0.2 alone didn't work for me as I'm using React with TypeScript. The solution that worked for me is as follows:

  1. Uninstall v2.1.1
    
  2. Install v2.0.2
    
  3. Go to this path: "node_modules > stylis-plugin-rtl > stylis-rtl.d.ts". Open the "stylis-rtl.d.ts" file and remove all codes. Then, replace them with these codes.
    

import { Middleware } from 'stylis'; declare type MiddlewareParams = Parameters<Middleware>; declare function stylisRTLPlugin(element: MiddlewareParams[0], index: MiddlewareParams[1], children: MiddlewareParams[2], callback: MiddlewareParams[3]): string | void; export default stylisRTLPlugin; //# sourceMappingURL=stylis-rtl.d.ts.map

@helhahel
Copy link

i have the same error

To ignore, add // eslint-disable-next-line to the line before.

WARNING in ./node_modules/stylis-plugin-rtl/dist/stylis-rtl.js
Module Warning (from ./node_modules/source-map-loader/dist/cjs.js):
Failed to parse source map from 'E:_ UR_final project\eggWebApp\material-dashboard-react-main\node_modules\stylis-plugin-rtl\src\stylis-rtl.ts' file: Error: ENOENT: no such file or directory, open 'E:_ UR_final project\eggWebApp\material-dashboard-react-main\node_modules\stylis-plugin-rtl\src\stylis-rtl.ts'

Any solution?

@turkmuhendisnet
Copy link

Copying Files with a Postinstall Script
If you are using the package as is and want to manually add the source files, you can use a postinstall script.

Using a postinstall Script in package.json:

{
"scripts": {
"postinstall": "cp -r node_modules/stylis-plugin-rtl/dist/* node_modules/stylis-plugin-rtl/src/"
},
// Other fields
}

This script copies the files from the dist directory to the src directory when you run npm install or yarn install.

@ousszizou
Copy link

you can try to solve this warning with below steps. for me its working

  1. create .env file on root
  2. add this line : GENERATE_SOURCEMAP=false

Thats it !! re-run the project.

worked for me, thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.