Skip to content

Interpolate %REACT_APP_...% in public/robots.txt #8004

Closed
@davetapley

Description

@davetapley

Is your proposal related to a problem?

%REACT_APP_...% are interpolated in public/index.html but not in public/robots.txt.

IMHO it would be more consistent to apply this to all files in public/ (see Additional context).

This has also come up on #6568.

Describe the solution you'd like

Be able to use %REACT_APP_...% in (at least) public/robots.txt (but optionally all files in public/).

Describe alternatives you've considered

Injecting the correct values in as part of our deployment process.

Additional context

The docs are little inconsistent on this: The ones for the public folder in general state:

None of the files in public folder get post-processed or minified.

But then the env vars docs state:

You can also access the environment variables starting with REACT_APP_ in the public/index.html.

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