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

Uncaught TypeError: html_to_figma_1.htmlToFigma is not a function #75

Open
studiotimo opened this issue Aug 11, 2021 · 2 comments
Open

Comments

@studiotimo
Copy link

Hello,

I was trying to run chrome extension and I'm stuck because when I tried to run it with npm run watch command, it threw this error as soon as I clicked on the "Capture Current Page" button:

Uncaught TypeError: html_to_figma_1.htmlToFigma is not a function

Screen Shot 2021-08-11 at 2 07 55 PM

Do you have any idea what I can do now? Please advise.

Thank you.

@steve8708
Copy link
Collaborator

hey @studiotimo - that's odd, I just did the following and it worked as expected, are these any different than your steps?

cd chrome-extension
npm install
npm run watch

then I went to chrome://extensions and chose "load unpacked" and then chose chrome-extension/dist folder

then I went to disney.com and found the HTML <> Figma extension and chose "Capture current page" and it downloaded as expected

@studiotimo
Copy link
Author

studiotimo commented Aug 18, 2021

Thanks, @steve8708 . I tried it again from scratch, but this time, for some reason, I'm having trouble in npm install. I got a lot of errors related to libsass. (Please see the attached screenshot.) This stackoverflow thread shows the same kind of error message in console. I guess this has something to do with Node.js version, node-sass version, and etc. Could you share the version number of Node.js and node-sass in your computer? (My Node.js version was v14.17.4 (and I tried upgrading to v16.7.0) and it didn't work either way.)

On the other hand, I found a workaround by bundling inject.ts only, instead of using npm run watch command. So I'm able to run the chrome extension locally. Since the issue is not a blocker for me, you may close this issue if you want. If you can add your version number of Node.js and node-sass, though, before closing this, it could be helpful for me and others. Thank you!

Screen Shot 2021-08-18 at 10 32 43 AM

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

No branches or pull requests

2 participants