Skip to content

error with symfony - encore - webpack #73

@gabrielnn77

Description

@gabrielnn77

I'm using a Symfony 6.4 project with the webpack/encore tools to use PHP on the server side, and Solid on the client side.
When yarn tries to compile, I get the following error:
ERROR Failed to compile with 1 errors

Error loading ./node_modules/solid-icons/lib/index.jsx

FIX To process React JS files:
1. Add Encore.enableReactPreset() to your webpack.config.js file.
2. Install @babel/preset-react to use enableReactPreset()
yarn add @babel/preset-react@^7.9.0 --dev

I was able to solve it by deleting the file ./node_modules/solid-icons/lib/index.jsx, and copying the file ./node_modules/solid-icons/lib/index.js in its place

I'm not using React in this project, I don't understand what's causing this error, and I'm not using TypeScript either.
Sorry for my bad English

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions