brtnshrdr / angular2-hotkeys

Keyboard shortcuts for Angular 2 apps
MIT License
203 stars 95 forks source link

After updating to v15.0.0, a type definition error regarding mousetrap occurs. #170

Closed negibouze closed 1 year ago

negibouze commented 1 year ago

Thank you for your great library.

I have a thing that I want to inform you. After updating to v15.0.0, I am getting the following error.

Could not find a declaration file for module 'mousetrap'. '/node_modules/angular2-hotkeys/node_modules/mousetrap/mousetrap.js' implicitly has an 'any' type.
  Try `npm i --save-dev @types/mousetrap` if it exists or add a new declaration (.d.ts) file containing `declare module 'mousetrap';`

import { MousetrapInstance } from 'mousetrap';

I think it's because @types/mousetrap was moved from dependencies to devDependencies between v13.4.0 and v15.0.0. https://github.com/brtnshrdr/angular2-hotkeys/compare/v13.4.0...v15.0.0

If there is no problem, I think it would be better to return it to dependencies, what do you think?

Coffee-Tea commented 1 year ago

Track here https://github.com/brtnshrdr/angular2-hotkeys/pull/168

Coffee-Tea commented 1 year ago

@negibouze fixed in v16.0.1

https://www.npmjs.com/package/angular2-hotkeys/v/16.0.1

please test it out and let here know if it didn't help.

negibouze commented 1 year ago

@Coffee-Tea Thank you! :)