Using this with Next JS - without dynamic import?
siliconjungle opened this issue · comments
James Addison commented
Hey everyone, is there a solution to using this with Next JS on the backend?
Nikolay commented
What's the issue
James Addison commented
Importing this: import TimeAgo from 'javascript-time-ago/modules/TimeAgo';
ends up producing the following error: SyntaxError: Cannot use import statement outside a module
.
Nikolay commented
You shouldn't import anything like that