-
Notifications
You must be signed in to change notification settings - Fork 13
Description
I found this project after bootstrapping a Nuxt 4 TypeScript project via npx nuxi init, and rolling with their eslint support by selecting to use module @nuxt/eslint.
Here's what I did after npx nuxi init. First, I renamed eslint.config.mjs to eslint.config.ts. I wanted to use Prettier, and I ended up at https://prettier.io/docs/related-projects#eslint-integrations. I thought to myself, "Self, using all of those packages would be a good idea, 'cause I'm a big fan of standard" (BTW, I didn't think of the URL -- I added it later in this text). As I embarked upon installing those, I read https://github.com/sheerun/prettier-standard#examples, which recommends this project and https://github.com/okonet/lint-staged. Fine. I installed this & lint-staged. I also installed husky, because I thought I needed it.
This issue is to request that you provide preconfigured example projects, because that was a lot of boilerplate activity, and I expected a project named modern-node to have already dialed all that in. Because I'm selfish, I'd love the first one to be an npm-based Node.js project using TypeScript that has all of these features (even better if it were a Nuxt project using @nuxt/eslint, but that's prolly going too far). Supermegaultrahyperbonus** points for implementing #28.
PS: In the absence of a sample modern-node project, I thought, "Why, modern-node itself ought to be a modern node project, right?" So looked, in hopes of just copying from your package.json, but, to my surprise, it doesn't appear to be. The project might consider dogfooding.
PPS: After completing all the steps above for my Nuxt project, here is my package.json, and, I was a little nervous when I, after feeling the tingles of excitement of trying something new, saw the output of npm run format, because there were was a deprecation warning & a scary TypeError, and tool returned exit code 2. See below. Completing this issue would include tackling things like that ahead of time so stuff Just Works™️ for people.
$ bash --version # just FYI; on Linux Mint XFCE 22.x
GNU bash, version 5.2.21(1)-release (x86_64-pc-linux-gnu)
Copyright (C) 2022 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
$ node --version # just FYI
v22.17.1
$ npm --version # just FYI
10.9.2
$ npm run format
> format
> modern format
.nuxt/app.config.mjs 98ms
.nuxt/components.d.ts 482ms
.nuxt/eslint.config.mjs 40ms
.nuxt/imports.d.ts 26ms
.nuxt/manifest/meta/e8fbf436-f243-4545-94dc-293cbc6e9647.json 7ms
.nuxt/nuxt-icon-client-bundle.mjs 6ms
.nuxt/nuxt-icon-server-bundle.mjs 8ms
.nuxt/nuxt.d.ts 9ms
.nuxt/nuxt.json 6ms
.nuxt/nuxt.node.d.ts 6ms
.nuxt/nuxt.shared.d.ts 5ms
.nuxt/schema/nuxt.schema.d.ts 28ms
.nuxt/schema/nuxt.schema.json 30ms
.nuxt/tsconfig.app.json 14ms
.nuxt/tsconfig.json 17ms
.nuxt/tsconfig.node.json 12ms
.nuxt/tsconfig.server.json 13ms
.nuxt/tsconfig.shared.json 9ms
(node:1231318) [DEP0128] DeprecationWarning: Invalid 'main' field in '/media/storage/matthew/dev/me/mailacheck-nuxt4/node_modules/find-parent-dir/package.json' of 'find-parent-dir.js'. Please either fix that or report it to the module author
(Use `node --trace-deprecation ...` to show where the warning was created)
TypeError: Cannot read properties of undefined (reading 'map')
at Converter.convertNode (/media/storage/matthew/dev/me/mailacheck-nuxt4/node_modules/prettierx/node_modules/@typescript-eslint/typescript-estree/dist/convert.js:2065:53)
at Converter.converter (/media/storage/matthew/dev/me/mailacheck-nuxt4/node_modules/prettierx/node_modules/@typescript-eslint/typescript-estree/dist/convert.js:72:29)
at Converter.convertType (/media/storage/matthew/dev/me/mailacheck-nuxt4/node_modules/prettierx/node_modules/@typescript-eslint/typescript-estree/dist/convert.js:153:21)
at /media/storage/matthew/dev/me/mailacheck-nuxt4/node_modules/prettierx/node_modules/@typescript-eslint/typescript-estree/dist/convert.js:230:60
at Array.map (<anonymous>)
at Converter.convertTypeArgumentsToTypeParameters (/media/storage/matthew/dev/me/mailacheck-nuxt4/node_modules/prettierx/node_modules/@typescript-eslint/typescript-estree/dist/convert.js:230:35)
at Converter.convertNode (/media/storage/matthew/dev/me/mailacheck-nuxt4/node_modules/prettierx/node_modules/@typescript-eslint/typescript-estree/dist/convert.js:1691:32)
at Converter.converter (/media/storage/matthew/dev/me/mailacheck-nuxt4/node_modules/prettierx/node_modules/@typescript-eslint/typescript-estree/dist/convert.js:72:29)
at Converter.convertType (/media/storage/matthew/dev/me/mailacheck-nuxt4/node_modules/prettierx/node_modules/@typescript-eslint/typescript-estree/dist/convert.js:153:21)
at Converter.convertNode (/media/storage/matthew/dev/me/mailacheck-nuxt4/node_modules/prettierx/node_modules/@typescript-eslint/typescript-estree/dist/convert.js:1793:42)
2025-07-21 08:18:56 ⌚ vader in /media/storage/matthew/dev/me/mailacheck-nuxt4
$ echo $?
2
**: Prolly not really a word, but likely grammatically correct, as super, ultra, mega, and hyper are all prefixes.