We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
We use commander.js for creating CLI. There is a strange behavior which more a bug than a feature.
When user makes a mistake and uses "-name" option instead "--name" commander is parsing it as "-n ame".
So, for the command
npx fontpie ./roboto-regular.ttf -name "Roboto"
our user gets
@font-face { font-family: 'ame'; ^^^^^ font-style: normal; font-weight: 400; font-display: swap; src: url('examples/roboto-regular.ttf') format('truetype'); } @font-face { font-family: 'ame Fallback'; ^^^^^ font-style: normal; font-weight: 400; src: local('Times New Roman'); ascent-override: 84.57%; descent-override: 22.25%; line-gap-override: 0.00%; size-adjust: 109.71%; } html { font-family: 'ame', 'ame Fallback'; ^^^^^ }
Show error to user in terminal and stop execution.
Use font filename as font name in CSS and show notice to user in terminal.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
We use commander.js for creating CLI. There is a strange behavior which more a bug than a feature.
When user makes a mistake and uses "-name" option instead "--name" commander is parsing it as "-n ame".
So, for the command
npx fontpie ./roboto-regular.ttf -name "Roboto"
our user gets
Acceptable fix
Show error to user in terminal and stop execution.
Ideal fix
Use font filename as font name in CSS and show notice to user in terminal.
The text was updated successfully, but these errors were encountered: