Skip to main content
Question

Build fails after installing Figma new linter


Hi, i’m trying to migrate the Figma plugin to Dynamically Load Pages, followed the instructions here: Migrating Plugins to Dynamically Load Pages | Plugin API

And after i installed the linter the build fails with this error:

  error TS2688: Cannot find type definition file for '@types/eslint-plugin-figma-plugins'.
      The file is in the program because:
        Entry point of type library '@types/eslint-plugin-figma-plugins' specified in compilerOptions

Anyone had this issue?

4 replies

ksn
Figmate
  • Community Support
  • 1611 replies
  • March 7, 2024

Hey @TaylorT - I saw that you wrote into our support team about this. I made note of this topic on the ticket you have already, and someone will get back to you. I think it’s best for this one to be answered by them (they are much more knowledgeable on API related stuff than I am 😅)


  • Author
  • 7 replies
  • March 10, 2024

Hi,
Thank you! I got an answer with some irrelevant articles…
I fixed this issue by adding “types”:[“node”] to compilerOptions in tsconfig.
BUT now the new methods do not exist on the API:
Property 'getNodeByIdAsync' does not exist on type 'PluginAPI'
How do I fix it?


y_toku
Figmate
  • Community Support
  • 2320 replies
  • March 12, 2024

Hi there,

I noticed that you’ve already reached out to our support team, and I believe it would be best to keep the conversation centralized there. Would you mind also sending an email to our support team? Your ticket number is #942351.

Thank you for your patience and understanding!
Toku


jefflee
Figmate
  • Figmate
  • 22 replies
  • March 12, 2024

@TaylorT The “property missing” error you’re getting is probably because your project doesn’t have the most recent version of our TypeScript types. Try running npm update @figma/plugin-typings in your project folder. The property in the error message you posted was added to the type definition in version 1.87. See: Version 1, Update 87 | Plugin API


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings