tangledbytes / nodejs-snowflake

Generate time sortable 64 bits unique ids for distributed systems (inspired from twitter snowflake)
https://www.npmjs.com/package/nodejs-snowflake
Apache License 2.0
176 stars 15 forks source link

Issue in type definitions (semicolon) #16

Closed OfficialCRUGG closed 2 years ago

OfficialCRUGG commented 2 years ago

Hello there, I added nodejs-snowflake to a TypeScript project and it doesn't compile anymore due to the following error:

node_modules/nodejs-snowflake/nodejs_snowflake.d.ts(7,2): error TS1036: Statements are not allowed in ambient contexts.

This is due to the semicolon in line 7 of nodejs_snowflake.d.ts. If I manually remove this, my project compiles just fine.

tangledbytes commented 2 years ago

@OfficialCRUGG see if v2.0.1 fixes your issues.

OfficialCRUGG commented 2 years ago

Works! Thanks!