Syntax error "Identifier 'React' has already been declared. (4:7)" in 'layer5io-sisten/site/gatsby-browser.js"'
Description
Syntax error "Identifier 'React' has already been declared. (4:7)" in 'layer5io-sisten/site/gatsby-browser.js"'
STEPS
- cd site/
- make setup
- make site ==> ERROR UNKNOWN
Syntax error in "/Users/ilazarkov/Development/VSCodeProjects/layer5io-sisten/site/gatsby-browser.js": Identifier 'React' has already been declared. (4:7) 2 | import { ThemeProvider } from './src/components/Theme'; 3 | import './src/styles/global.css';
4 | import React from "react"; | ^ 5 | 6 | export const wrapRootElement = ({ element }) => <ThemeProvider>{element}</ThemeProvider>; 7 |
Expected Behavior
The site successfully started
Screenshots
Environment:
- Host OS: macOS Sequoia v15.5
- Browser:
Contributor Resources and Handbook
The layer5.io website uses Gatsby, React, and GitHub Pages. Site content is found under the master branch.
- π See contributing instructions.
- π¨ Wireframes and designs for Layer5 site in Figma (open invite)
- ππΎππΌ Questions: Discussion Forum and Community Slack.
Join the Layer5 Community by submitting your community member form.
Hi @M-DEV-1 would you please assign this issue to me?
I read the CONTRIBUTING.md and by removing duplicate Reac import it worked for me.
Thank you.
Provided PR https://github.com/layer5io/sistent/pull/1077
Screenshot of a fix
make site
Hi, I'd love to work on this issue. Is it still up for grabs?
Hi, I'd love to work on this issue. Is it still up for grabs?
It's been fixed and it's being merged (the PR is approved but not merged). Once the OR is merged I'll close this issue. If you are looking out for issue I would recommend to explore around the site package I think there are things can be found and improved/fixed.