-
Notifications
You must be signed in to change notification settings - Fork 79
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
getting to work in NextJS? #151
Comments
Anyone familiar with NextJS that can help out with this? |
I think the problem with your example is that the So, I think you'll need to execute it for each element that uses it, then retrieve the updated element, something like:
|
I have the same problem. Why wouldn't it work, for instance, if triggered via console? |
This package is working for me: https://www.npmjs.com/package/react-balance-text |
Possibly related: Text gets deleted / cut off (#152) |
This works for me in NextJS.
|
@giyeonkwon Doing so you get I made my own local js with the content from the library and load it async: |
Hey there — such a great tool for making text more visually appealing online.
I have used this in non-React based sites but am struggling to get it to work within React/NextJS/Gatsby based sites.
In Next I have tried this in my
_app.js
:and I have also tried this in my pages:
But none of these appear to work, even with the above, if I visit my site in browser and do
balanceText();
in console, it picks up the command but isn't applied to any text that has thebalance-text
class, just gets completely ignored, any ideas?The text was updated successfully, but these errors were encountered: