Skip to content

Source License notice strip #6441

Open
Open
@ghost

Description

I have a project, for example:

Example
package.json
{
  "...": "",
  "main": "index.js",
  "scripts": {
    "...": "",
    "build": "react-scripts build"
  },
  "dependencies": {
    "...": "",
    "react-scripts": "2.1.5"
  }
}

index.js

/*!
 * project
 * Copyright 2019 Igor Vuchastyi
 * Licensed under MIT
 */

// Some other code

When i run npm run build it executes react-scripts build, then it creates build directory like this build/static/{css,js}/*.{css,js}.
JS files doesn't contain any license i have specified at the index.js. If i do it with webpack - webpack collect my license and put at the top of bundle.

I think react-scripts strips my license from bundle and from other packages.

My problem: i don't want use react-scripts eject, i don't want use any other which is forks of react-scripts or etc.
My question: is there a way to leave my License notice at top of each chunk produced by react-scripts?
I was searching for around 2 hours. Was googling, was searching in this repository. Found nothing about this thread.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions