Skip to content

"No loaders configured to process this file" #15

@Jensderond

Description

@Jensderond

Hello, we were trying to integrate Swingset in our application to have a less heavy platform to display our components on.

Despite reading in your README that it is not recommended for use, we hoped to give it a shot. Unfortunately I can't seem to get it working properly.

I get the following error message:

./node_modules/swingset/page.jsx 33:6
Module parse failed: Unexpected token (33:6)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
| 
|     return (
>       <div className={s.root}>
|         <Head>
|           <title key="title">Component Library</title>

I've tried installing next-transpile-modules to hope to fix this issue but that resulted in another error message:

Server Error
TypeError: Cannot read property 'src' of undefined

../../pages/_document.tsx (86:33) @ Function.getInitialProps

    |     }
    | 
 >  |     const { html, head } = await ctx.renderPage({ enhanceApp })
    |                                 ^
    |     const styles = [...flush()]
    |     return { html, head, styles }
    |   }

We're using the latest version of next ( 10.0.7 ) and are using TSX for all our components.

I totally understand if you'd close this issue. 😄

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions