You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to use this plugin within our Aurelia application. I'm using webpack as our bundler and have installed the aurelia-react-loader plugin via npm.
When I try to do the following: <require from='@nike/frame-component-library/src/components/nav/Nav.js!react-component'></require>
I get an error stating that the file cannot be found. However, if I drop the !react-component suffix the file is found but I get an Unexpected token error due to the JSX.
Any help would be appreciated, thanks!
The text was updated successfully, but these errors were encountered:
When I wrote this Webpack support in Aurelia was experimental, and I never got around to trying out the loader with it. I'd like to get it working, but I'm not sure when I'll have the time.
Are you able to import other resources without errors? One problem I see is the JSX thing. This loader doesn't run any transforms. You will need to compile any JSX with babel (probably via a webpack loader config) before running it through the react-component loader.
Sorry I don't have a better answer for you right now. If you discover any changes that could be made to better support webpack I'd be happy to take a PR.
Hello,
I'm trying to use this plugin within our Aurelia application. I'm using webpack as our bundler and have installed the aurelia-react-loader plugin via npm.
When I try to do the following:
<require from='@nike/frame-component-library/src/components/nav/Nav.js!react-component'></require>
I get an error stating that the file cannot be found. However, if I drop the
!react-component
suffix the file is found but I get anUnexpected token
error due to the JSX.Any help would be appreciated, thanks!
The text was updated successfully, but these errors were encountered: