Where to add license credit in React?

Hi, I would like to use one of these loaders https://github.com/lukehaas/css-loaders/ in React, but I don’t know where to add the credits. A comment in SCSS gets removed and as far as I know from JSX as well … Where would you put it?

Is your HTML file set up such that you could put a credit comment there (before the React elements render)?

1 Like

Why do you feel the need to do this? People won’t look through your bundled js and anyone seeing the source code can see where it came from by looking in the package.json. We use a lot of opens source packages (including react and redux and babel etc.). What about this one makes you think it needs a special nod?

@nhcarrigan Yes, that would work. Thanks.

@kevinSmith This is the first time I am using a spinner and I was following a tutorial where the instructor copied the CSS directly from this project. (There is an editor for background colors on the project homepage, maybe that’s why.) I am fairly new to React and it didn’t cross my mind to import a spinner via npm. (I’m guessing that you mean it would end up that way in the package.json) So I looked up the license on GitHub and it is MIT and said ‘Conditions: License and copyright notice’. That’s what made me think I have to add it manually … but from your words it sounds like that’s not the usual way people go about it …

1 Like

As said I’m not so sure how useful credits in comments are anyway. If you want you can always add credits to something like a footer or an about page.

I think the MIT license requirement is for when you copy/use the full software, i.e. fork the full project and change or use it in some new way. Then the original license (and copyright) must be preserved (at least I think that is what it means).

https://tldrlegal.com/license/mit-license

2 Likes

I see, thanks for that clarification.

Yeah, definitely, that is the normal way to do it. I’m not sure about cutting and pasting the code - maybe he just did that so s/he wouldn’t have to explain npm, etc.

Unless the license says explicitly that you have to credit them, I wouldn’t worry about it. If you were forking off this and creating your own spinner package, then I think it would be a good thing to mention in the readme.

1 Like