Skip to content

Conditionally output serve instructions #2750

Closed
@evenstensberg

Description

@evenstensberg

Is this a bug report?

No, Enhancement Request

Summary

If you've got serve already installed globally, asking users to install it becomes redundant.

Example:

skjermbilde 2017-07-08 kl 21 08 23

Current Implementation

Current implementation is that the same instruction gets outputted, even though you'd have serve installed after running yarn build

Proposed

  1. Check global prefix and where the users global folder is installed
  2. Print stdout message if it doesn't exist

Use process.argv to map back to where the global folder is, or you could add global-prefix as a dependency.

https://github.com/facebookincubator/create-react-app/blob/a171d930641f513279b1c7ceaab1fa9bbbbbb896/packages/react-dev-utils/printHostingInstructions.js#L124-L131


Happy hacking :)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions