Next.js Discord

Discord Forum

can't use anything inside Loading.js file

Answered
Serbian Hound posted this in #help-forum
Open in Discord
Serbian HoundOP
i'm trying to use html, components, but nothing works, typescript is just letting me use a raw string on return of loading file. what i'm doing wrong?
Answered by LuisLl
.tsx/.jsx extension helps with the HTML-like syntax (JSX). Change .ts to .tsx and it'll work as you expect.
View full answer

2 Replies

.tsx/.jsx extension helps with the HTML-like syntax (JSX). Change .ts to .tsx and it'll work as you expect.
Answer
Serbian HoundOP
OHH!! that's true! thank you. im feeling blind now lol