-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adds TypeScript support for configuration file #219
Comments
Hello @folke, could you please take a look here when you can? |
Hey @folke I am not giving up, I still want this to be evaluated and merged! Could you please take a look here? |
If it's any help, I use JSDoc type-checking in my JS files which gets me the type-safety I'm looking for. It's not the same thing as explicit TS support, but it works well enough for me.
// @ts-check
/**
* @type import('devmoji/lib/config-options').ConfigOptions
*/
const config = {
types: ['feat', 'fix', 'docs', 'style', 'refactor', 'perf', 'test', 'chore', 'build', 'ci'],
devmoji: [
{
code: 'feat',
description: 'a new feature',
emoji: '🌠',
},
// ...
]
} |
Thanks for the reply @ap0nia, but my main issue is with the file extension itself! My projects do not have any .js files but this one from devmoji, my main goal here is to have only .ts files in my src folder! In theory my PR fixes/ provides that, but I can't merge, I need someone to approve and merge this! |
Description
Hello, I love adding emojis to my commits and recently I found this repository to be a good tool to automate this process to me and also other devs of projects I work on. The thing is, I like TypeScript and have a tendency of not allowing any .js files in projects I work with. The fact this project only supported configuration file in .js format kind of bothered me a little, so I decided to add typescript support for the configuration file
devmoji.config.ts
.The PR is here: #220
Type of change
How Has This Been Tested?
I ran all the test suits with both
yarn test
andyarn test:cov
and provided a new test to the new typescript configuration file.(Also tried to improve coverage a bit by adding a test for a uncovered scenario
config file does not exist
).Checklist:
The text was updated successfully, but these errors were encountered: