1
0
mirror of https://github.com/simple-icons/simple-icons.git synced 2024-11-26 01:00:27 +02:00
Commit Graph

10 Commits

Author SHA1 Message Date
Eric Cornelissen
9fdbb57ccc
Add guidelines data to NPM package and documenation (#5342) 2021-03-26 09:33:04 +00:00
Eric Cornelissen
95109ad629
Add license data to NPM package and documenation (#5106) 2021-03-02 12:01:31 +00:00
Eric Cornelissen
8431fd9683
Simplify how scripts get icon slugs (#5066)
* Accept icon rather than title in `iconToSlug`

This removes the need in (most of the) calls to this function to
seperately check if there is a custom slug already defined for the icon.

* Rename `titleToSlug` to `getIconSlug`

* Revert unnecessary style change

* Update function documentation

* Keep `titleToSlug` and add `getIconSlug` helper

Unfortunately `this` is not available because we're using arrow syntax
for these functions, but refering to `titleToSlug` through
`module.exports` works fine as well.

* Fix parameter name in `getIconSlug` docs
2021-02-22 14:15:37 +01:00
Eric Cornelissen
9c029bc706
Allow custom slugs (#4918) 2021-02-19 13:06:43 +00:00
Eric Cornelissen
8ecfcafeba
Refactor scripts in scripts/ (#4931)
- Rename `titleToFilename` to `titleToSlug`
- Fix indentation where necessary
- Use quotes internally consistently (to reduce the diff size, unfortunately this is the opposite quote from what we use in other projects)
- Update comments & documentation
- Construct file paths

And more...
2021-02-08 17:14:31 +01:00
Eric Cornelissen
7fb4ff6395
Fix low severity issues in the JavaScript (#3342) 2020-07-28 11:33:40 +01:00
Eric Cornelissen
412ccc0a6d
Escape icon title for object key (#2710) 2020-03-02 10:49:56 +00:00
Eric Cornelissen
93425f8aa0 No longer require no final newline in SVGs (#1682)
* Introduce newline into a SVG

for testing purposes

* Remove potential newlines from SVGs when building the package

* Don't lint SVG files

... so it is neither required to have, or not have, a final newline

* Remove both Windows and Unix style newlines in build script

* Rever 3372ca3
2019-09-30 18:34:42 +02:00
Eric Cornelissen
87ab9c43a7 Refactor prepublish script to use template file for icon objects (#1547)
* Refactor prepublish script to use template file for icon objects

... to hopefully increase readability

* Fix build and test issues

* Add missing semi-colon

* Explicitly check for errors when writing individual static .js files
2019-08-15 13:23:35 +02:00
Eric Cornelissen
11cdbd7073 Add a "build" and "clean" NPM script (#1548) 2019-07-22 09:58:51 -07:00