jaywcjlove / hotkeys-js

➷ A robust Javascript library for capturing keyboard input. It has no dependencies.
https://jaywcjlove.github.io/hotkeys-js
MIT License
6.57k stars 405 forks source link

3.13.0 版本在angular16项目中引用报错 TS2309 #464

Open wh131462 opened 7 months ago

wh131462 commented 7 months ago

今天更新代码,拉取最新版本之后报错 Error: node_modules/hotkeys-js/index.d.ts:181:1 - error TS2309: An export assignment cannot be used in a module with other exported elements.

181 export = hotkeys;

image ![Uploading image.png…]()

/* To learn more about this file see: https://angular.io/config/tsconfig. */
{
  "compileOnSave": false,
  "compilerOptions": {
    "baseUrl": "./",
    "outDir": "./dist/out-tsc",
    "forceConsistentCasingInFileNames": true,
    "strict": true,
    "noImplicitOverride": true,
    "noPropertyAccessFromIndexSignature": true,
    "noImplicitReturns": true,
    "noFallthroughCasesInSwitch": true,
    "sourceMap": true,
    "declaration": false,
    "downlevelIteration": true,
    "experimentalDecorators": true,
    "moduleResolution": "node",
    "importHelpers": true,
    "target": "ES2022",
    "module": "ES2022",
    "useDefineForClassFields": false,
    "lib": [
      "ES2022",
      "dom"
    ]
  },
  "angularCompilerOptions": {
    "enableI18nLegacyMessageIdFormat": false,
    "strictInjectionParameters": true,
    "strictInputAccessModifiers": true,
    "strictTemplates": true
  }
}
jaywcjlove commented 7 months ago

@wh131462 这可能是我合并 #441 造成的,我测试一下

jaywcjlove commented 7 months ago

@wh131462 修复了这个问题