Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • C create-react-app
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 1,547
    • Issues 1,547
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 417
    • Merge requests 417
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Meta
  • create-react-app
  • Issues
  • #3052
Closed
Open
Issue created Sep 02, 2017 by Nick McCurdy@nickmccurdy

Support index.jsx entry file

While I understand that the jsx extension is supported but not recommended, I was surprised that my index.jsx file isn't being recognized after renaming it to pass eslint-config-airbnb's jsx extension requirement.

Is this a bug report?

Sort of, I was surprised this wasn't supported but it may be an intentionally missing feature.

Which terms did you search for in User Guide?

index.js, it's clear that it's currently expected for the filename to be an exact match.

Steps to Reproduce

  1. Rename index.js to index.jsx
  2. npm start

Expected Behavior

App runs normally, treating index.jsx as the same as index.js when it's not present.

Actual Behavior

> react-scripts start

Could not find a required file.
  Name: index.js
  Searched in: /Users/nick/Repos/password-entropy/src
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @ start: `react-scripts start`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the @ start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
Assignee
Assign to
Time tracking