Skip to content

Commit

Permalink
Rewrite project
Browse files Browse the repository at this point in the history
  • Loading branch information
wooorm committed Oct 25, 2024
1 parent 31d464e commit c673898
Show file tree
Hide file tree
Showing 13 changed files with 617 additions and 781 deletions.
8 changes: 4 additions & 4 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
root = true

[*]
indent_style = space
indent_size = 2
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
end_of_line = lf
indent_size = 2
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true
27 changes: 11 additions & 16 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,28 +1,23 @@
name: main
on:
push:
branches:
- main
schedule:
- cron: '45 7 2 * *'
jobs:
main:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
persist-credentials: false
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: node
- run: npm install
- run: npm test
- name: Deploy
uses: JamesIves/github-pages-deploy-action@releases/v4
- uses: JamesIves/github-pages-deploy-action@releases/v4
with:
branch: gh-pages
folder: dest
single-commit: true
commit-message: .
git-config-name: Titus Wormer
folder: dest
git-config-email: tituswormer@gmail.com
git-config-name: Titus Wormer
single-commit: true
name: main
on:
push:
branches:
- main
10 changes: 6 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
.DS_Store
*.log
*.d.ts
node_modules/
dest/
node_modules/
*.d.ts
*.log
*.map
*.tsbuildinfo
.DS_Store
yarn.lock
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
ignore-scripts=true
package-lock=false
1 change: 0 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
dest/
*.html
*.json
*.md
2 changes: 1 addition & 1 deletion license
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
(The MIT License)

Copyright (c) 2017 Titus Wormer <tituswormer@gmail.com>
Copyright (c) Titus Wormer <tituswormer@gmail.com>

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
Expand Down
144 changes: 79 additions & 65 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,87 +1,101 @@
{
"name": "www-readability",
"license": "MIT",
"repository": "wooorm/readability",
"bugs": "https://github.com/wooorm/readability/issues",
"author": "Titus Wormer <tituswormer@gmail.com> (https://wooorm.com)",
"browserslist": [
"> 1%",
"last 2 versions",
"not ie <= 8"
],
"bugs": "https://github.com/wooorm/readability/issues",
"contributors": [
"Titus Wormer <tituswormer@gmail.com> (https://wooorm.com)",
"Michael Chambers <chamicr@gmail.com>"
"Titus Wormer <tituswormer@gmail.com> (https://wooorm.com)"
],
"type": "module",
"dependencies": {
"compute-mean": "^3.0.0",
"compute-median": "^2.0.0",
"debounce": "^1.0.0",
"global": "^4.0.0",
"lerp": "^1.0.0",
"readability-scores": "^1.0.0",
"retext-english": "^4.0.0",
"retext-stringify": "^3.0.0",
"unified": "^10.0.0",
"unlerp": "^1.0.0",
"virtual-dom": "^2.0.0"
},
"devDependencies": {
"@types/debounce": "^1.0.0",
"@types/virtual-dom": "^2.0.0",
"cssnano": "^5.0.0",
"esbuild": "^0.15.0",
"postcss-cli": "^10.0.0",
"prettier": "^2.0.0",
"rehype-cli": "^11.0.0",
"rehype-preset-minify": "^6.0.0",
"rehype-prevent-favicon-request": "^3.0.0",
"remark-cli": "^11.0.0",
"remark-preset-wooorm": "^9.0.0",
"stylelint": "^14.0.0",
"stylelint-config-standard": "^29.0.0",
"@types/d3-array": "^3.0.0",
"@types/nlcst": "^2.0.0",
"@types/react": "^18.0.0",
"@types/react-dom": "^18.0.0",
"automated-readability": "^2.0.0",
"coleman-liau": "^2.0.0",
"cssnano": "^7.0.0",
"d3-array": "^3.0.0",
"dale-chall": "^2.0.0",
"dale-chall-formula": "^2.0.0",
"esbuild": "^0.24.0",
"flesch": "^2.0.0",
"gunning-fog": "^2.0.0",
"lerp": "^1.0.0",
"nlcst-to-string": "^4.0.0",
"parse-english": "^7.0.0",
"postcss-cli": "^11.0.0",
"postcss-preset-env": "^10.0.0",
"prettier": "^3.0.0",
"react": "^18.0.0",
"react-dom": "^18.0.0",
"rehype-cli": "^12.0.0",
"rehype-preset-minify": "^7.0.0",
"rehype-prevent-favicon-request": "^4.0.0",
"remark-cli": "^12.0.0",
"remark-preset-wooorm": "^10.0.0",
"smog-formula": "^2.0.0",
"spache": "^2.0.0",
"spache-formula": "^2.0.0",
"stylelint": "^16.0.0",
"stylelint-config-standard": "^36.0.0",
"syllable": "^5.0.0",
"type-coverage": "^2.0.0",
"typescript": "^4.0.0",
"xo": "^0.53.0"
},
"scripts": {
"build": "tsc --build --clean && tsc --build && type-coverage",
"format": "remark . -qfo && prettier . -w --loglevel warn && xo --fix && stylelint src/index.css --fix",
"generate:js": "esbuild src/index.js --bundle --minify --target=es6 --outfile=dest/index.nomodule.js && esbuild src/index.js --bundle --minify --target=es2020 --format=esm --outfile=dest/index.module.js",
"generate:css": "postcss src/index.css > dest/index.css",
"generate:html": "rehype -u preset-minify -u prevent-favicon-request src -o dest",
"generate": "npm run generate:js && npm run generate:css && npm run generate:html",
"test": "npm run build && npm run format && npm run generate"
},
"stylelint": {
"extends": "stylelint-config-standard"
},
"prettier": {
"tabWidth": 2,
"useTabs": false,
"singleQuote": true,
"bracketSpacing": false,
"semi": false,
"trailingComma": "none"
},
"xo": {
"prettier": true,
"rules": {
"unicorn/prefer-dom-node-append": "off"
}
"typescript": "^5.0.0",
"unist-util-visit": "^5.0.0",
"unlerp": "^1.0.0",
"xo": "^0.59.0"
},
"license": "MIT",
"name": "www-readability",
"postcss": {
"plugins": {
"postcss-preset-env": {},
"cssnano": {
"preset": "default"
}
}
},
"prettier": {
"bracketSpacing": false,
"semi": false,
"singleQuote": true,
"tabWidth": 2,
"trailingComma": "none",
"useTabs": false
},
"private": true,
"remarkConfig": {
"plugins": [
"preset-wooorm"
"remark-preset-wooorm"
]
},
"repository": "wooorm/readability",
"typeCoverage": {
"atLeast": 100,
"detail": true,
"strict": true,
"ignoreCatch": true
"strict": true
},
"type": "module",
"scripts": {
"build": "tsc --build --clean && tsc --build && type-coverage",
"format": "remark --frail --output --quiet -- . && prettier --log-level warn --write -- . && xo --fix && stylelint src/index.css --fix",
"generate:css": "postcss --output dest/index.css -- src/index.css",
"generate:html": "rehype --frail --output dest/ --quiet --use rehype-preset-minify --use rehype-prevent-favicon-request -- src/",
"generate:js:module": "esbuild src/index.jsx --bundle --conditions=browser,production --define:process.env.NODE_ENV=\\\"production\\\" --format=esm --loader:.js=jsx --log-level=warning --minify --outfile=dest/index.module.js --target=es2020",
"generate:js:nomodule": "esbuild src/index.jsx --bundle --conditions=browser,production --define:process.env.NODE_ENV=\\\"production\\\" --loader:.js=jsx --log-level=warning --minify --outfile=dest/index.nomodule.js --target=es6",
"generate:js": "npm run generate:js:module && npm run generate:js:nomodule",
"generate": "npm run generate:css && npm run generate:html && npm run generate:js",
"test": "npm run build && npm run format && npm run generate"
},
"stylelint": {
"extends": "stylelint-config-standard"
},
"xo": {
"prettier": true,
"rules": {
"unicorn/prefer-code-point": "off"
}
}
}
6 changes: 3 additions & 3 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@

## Related

* [`write-music`](https://github.com/wooorm/write-music)
* [`common-words`](https://github.com/wooorm/common-words)
* [`short-words`](https://github.com/wooorm/short-words)
* [`write-music`](https://github.com/wooorm/write-music)
* [`common-words`](https://github.com/wooorm/common-words)
* [`short-words`](https://github.com/wooorm/short-words)

## License

Expand Down
Loading

0 comments on commit c673898

Please sign in to comment.