Topic: "MDB React Element" has no corresponding closing tag
                  
                  bgining2this
                  free
                  asked 6 years ago
                
Expected.- No syntax errors in Visual Studio Code.
Current.- Multiple syntax errors in MDBReact complaining that several elements have no closing tag when it is present.

                      
                      Piotr Glejzer
                      staff
                        answered 6 years ago
                    
Hello bgining2this,
I recommend installing prettier plugin.
and this errors happens because you are putting a jsxcode to js file and Visual Studio Code doesn't recognize that. There are a few ways to fix this problem. The easiest way is to change a file extension to .jsx instead .js and set to setting format on save to true in VSC. 
The next solution is that you can change Select Language Mode in VSC ( right bottom corner ) and also set to format on save. 
or you can set globally to recognize .jsx but you have to change settings with prettier https://prettier.io/blog/2017/08/29/1.6.0.html like this. .
Best,
Piotr
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Answered
- ForumUser: Free
 - Premium support: No
 - Technology: MDB React
 - MDB Version: 4.21.0
 - Device: Desktop
 - Browser: Chromium, Opera
 - OS: Arch Linux
 - Provided sample code: No
 - Provided link: No
 
chiok zechariah free commented 4 years ago
I have the same issue, how can I solve these ? thank you!
Krzysztof Wilk staff commented 4 years ago
Hi!
Did you try the solution below?
Keep coding!