This repository has been archived by the owner on Mar 2, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* add tests, remove unused functions (#9) * add tests, remove unused exported functions * remove blocking code for non-null assertions * fix testing error * adjust package manifest, oops. * bump version * remove non-null assertion warning * remove commented out code * Update README (#11) * update README * update README * update README * update README
- Loading branch information
Showing
12 changed files
with
4,178 additions
and
162 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Ignore everything: | ||
/* | ||
|
||
# Except the source files | ||
!/src | ||
|
||
# Exclude tests folder | ||
src/__tests__ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
{ | ||
"parser": "@typescript-eslint/parser", | ||
"parserOptions": { | ||
"project": "./tsconfig.json" | ||
}, | ||
"plugins": ["@typescript-eslint/eslint-plugin"], | ||
"extends": [ | ||
"eslint:recommended", | ||
"plugin:@typescript-eslint/eslint-recommended", | ||
"plugin:@typescript-eslint/recommended", | ||
"plugin:@typescript-eslint/recommended-requiring-type-checking", | ||
"prettier", | ||
"prettier/@typescript-eslint" | ||
], | ||
"rules": { | ||
/** | ||
0 = off | ||
1 = warn | ||
2 = error | ||
*/ | ||
"@typescript-eslint/explicit-function-return-type": "off" | ||
}, | ||
"overrides": [ | ||
{ | ||
"files": ["./src/index.ts"], | ||
"rules": { | ||
"@typescript-eslint/no-non-null-assertion": "off" | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,5 @@ | ||
# Dependancies | ||
node_modules/ | ||
|
||
# Log Files | ||
*.log | ||
# Build Files | ||
build | ||
|
||
# Git Ignore Specific | ||
# Dot Files | ||
.DS_Store | ||
|
||
# Built Files | ||
dist/ | ||
# Dependancies | ||
node_modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,29 @@ | ||
# GitHub Configuration Files | ||
.github | ||
|
||
# Testing Files | ||
__tests__ | ||
*.test.* | ||
|
||
# Dependancies | ||
node_modules/ | ||
node_modules | ||
|
||
# Source Files | ||
src | ||
|
||
# Log Files | ||
*.log | ||
|
||
# NPM Ignore Specific | ||
# Source Files | ||
src/ | ||
|
||
# Compiler Config | ||
tsconfig.json | ||
# Lock Files | ||
*.lock | ||
package-lock.json | ||
|
||
# Dotfiles | ||
.* | ||
|
||
# Configurations | ||
tsconfig.json | ||
tsconfig.tsbuildinfo | ||
|
||
# Results of `npm pack` | ||
*.tgz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,53 @@ | ||
{ | ||
"name": "@pqt/foreground", | ||
"version": "1.0.2", | ||
"description": "Validate a hexadecimal value, Convert hexadecimal to HSL, determine if the colour needs a light or dark foreground. ", | ||
"main": "dist/index.js", | ||
"repository": { | ||
"type": "git", | ||
"url": "ssh://[email protected]/pqt/foreground.git" | ||
}, | ||
"version": "1.0.3", | ||
"description": "Determine whether a given background color will need a light or dark foreground", | ||
"author": "Austin Paquette <[email protected]>", | ||
"license": "MIT", | ||
"private": false, | ||
"keywords": [], | ||
"main": "build/index.js", | ||
"types": "build/index.d.ts", | ||
"scripts": { | ||
"build": "tsc", | ||
"commit": "npx git-cz", | ||
"cz": "npm run commit", | ||
"dev": "tsc -w", | ||
"format": "echo \"Add prettier format! -> @pqt/foreground\"", | ||
"lint": "echo \"Add linter! -> @pqt/foreground\"", | ||
"test": "echo \"Write tests! -> @pqt/foreground\"" | ||
"build": "rimraf build && tsc", | ||
"dev": "rimraf build && tsc --watch", | ||
"format": "prettier ./{src,__{tests,mocks}__}/{**,**/**}/*.{js,jsx,ts,tsx} --write", | ||
"lint": "eslint src --ext=\".js,.jsx,.ts,.tsx\"", | ||
"test": "jest" | ||
}, | ||
"devDependencies": { | ||
"typescript": "^3.6.4" | ||
} | ||
"@types/jest": "^25.1.4", | ||
"@typescript-eslint/eslint-plugin": "^2.23.0", | ||
"@typescript-eslint/parser": "^2.23.0", | ||
"eslint": "^6.8.0", | ||
"eslint-config-prettier": "^6.10.0", | ||
"jest": "^25.1.0", | ||
"prettier": "^1.19.1", | ||
"rimraf": "^3.0.2", | ||
"ts-jest": "^25.2.1", | ||
"typescript": "^3.8.3" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/pqt/foreground" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/pqt/foreground/issues" | ||
}, | ||
"husky": { | ||
"hooks": { | ||
"pre-push": "npm run format && npm run lint && npm run test" | ||
} | ||
}, | ||
"jest": { | ||
"roots": [ | ||
"<rootDir>/src" | ||
], | ||
"testMatch": [ | ||
"**/__tests__/**/*.+(ts|tsx|js)", | ||
"**/?(*.)+(spec|test).+(ts|tsx|js)" | ||
], | ||
"transform": { | ||
"^.+\\.(ts|tsx)$": "ts-jest" | ||
} | ||
}, | ||
"license": "MIT" | ||
} |
Oops, something went wrong.