Skip to content
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

Fix types minor errors #710

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Fix types minor errors #710

wants to merge 3 commits into from

Conversation

H-L
Copy link

@H-L H-L commented Jun 18, 2024

Hello,

First of all thanks for your hard work on the v3.0.0 !

I recently updated the deps in a project I work on, and tsc prompted some minor TS errors from Strophe.

So here is a quick PR to fix the errors encountered :

  • In connection.js and connection.d.ts, at the addHandler method, the id parameter should be optional since it is already optional in Handler.constructor
  • In index.d.ts, Strophe and Connection were added to the export, for simplicity purposes

Let me know if you need any changes on the PR.

Best regards !

H-L added 3 commits June 18, 2024 11:40
Added Strophe and Connection types to export. It makes it easier to `import type { Connection } from 'strophe.js'`
@@ -37,7 +37,7 @@ import { $pres } from './builder.js';
* @property {Object.<string, string>} NS
* @property {XHTML} XHTML
*/
export const Strophe: {
declare const Strophe: {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you make this change by hand? These files are autogenerated (by running make types).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants