Skip to content

Add base typescript support#3

Open
joeyfigaro wants to merge 6 commits intoromellogoodman:mainfrom
joeyfigaro:main
Open

Add base typescript support#3
joeyfigaro wants to merge 6 commits intoromellogoodman:mainfrom
joeyfigaro:main

Conversation

@joeyfigaro
Copy link

@joeyfigaro joeyfigaro commented Nov 30, 2022

Closes #2

  • add and configure required dependencies
  • expand build process to output type declarations
  • add types to package.json for new declaration output
  • update README
  • rename index.js to index.ts
  • use @ts-nocheck to silence compiler errors and add ham-fisted typings to relevant function return values

6c671e1 includes a change that I'm not 100% sure on yet and was hoping to get your eyes on–there was a scope conflict for particle previously:

particles?.forEach((particle) => { // particle defined here
    particle.line = particle.line.filter((particle) => {  // particle also defined here
      return isInBound(particle[0], particle[1], width, height, margin); // which particle are we referring to here? The innermost?
    });
  });

Thank you in advance for your time and consideration!

EDIT: and the incredibly easy to use library. :)

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.

Add typescript definitions

1 participant