Annoying JSX completions

Every time I type `div` and then tab inside a JSX block, I get returned this nasty `HTMLDivElement` and I cannot get rid of it. It's driving me crazy.

What configuration property might be wrong?

0
10 comments

Do other Emmet abbreviations work for you inside JSX? enter `div` and hit Ctrl+Space - what can you see in completion list?

0
Avatar
Permanently deleted user

Oh well, I usually have lots of issues with ememt inside JSX. Till yesterday other completions worked just fine, but I guess I did someting wrong trying to fix `div` and `span` and I messed everything up.

0

Is Enable JSX Emmet turned on in Settings | Editor | Emmet | JSX?

Do you have any custom language injections set up in Settings | Editor | Language Injections?

0
Avatar
Permanently deleted user

Yes of course JSX Emmet is enabled... also HTML and CSS are. No custom injections, but there are a few built-in turned on...

I think the only additions are libraries and type definitions, because webstorm fails at recognizing most methods without them... lodash, jquery, react of course...

0

is the issue specific to certain project? Can you recreate it in a new React application, created with create-react-app?

0
Avatar
Permanently deleted user

The issue is not project specific. I can use react-create-app, make a new one, add a component and it always behaves the same.

The work around so far? Undo, then tab again. I made a quick screencast to show you that.

 

0

Please can you export your settings(File | export settings) and provide them along with your idea.log?

0
Avatar
Permanently deleted user

Thank you for your kind support :)

archive.zip

0

In Preferences | Editor | General | Code Completion, change Case sensitive completion: from None to First letter - does it make things any better?

1
Avatar
Permanently deleted user

Holy cow it works 🎉 Thanks Elena, I knew I was just making a blatantly naive mistake 🤣

0

Please sign in to leave a comment.