Skip to content

package.json: start script is not cross-platform friendly #7

@apolopena

Description

@apolopena

"start": "PORT=4000 react-scripts start" only works on macOS and some Linux distributions.
As per the issue solved here perhaps either remove the custom port number altogether.

Or use cross-env to allow the project to be started on port 4000 regardless of platform:
run
yarn add -D cross-env

and then change

"start": "PORT=4000 react-scripts start,"

to

start": "cross-env PORT=4000 react-scripts start",

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