How do I teach WebStorm 9 inspector to recognize Angular Material Design tags/attributes?

前端 未结 5 1193
萌比男神i
萌比男神i 2020-12-14 07:23

Currently, all my angular material HTML attributes are highlighted in yellow with WebStorm 9 (Mac OS X Yosemite) warning: \"Attribute [name] is not allowed here\".

<

5条回答
  •  执念已碎
    2020-12-14 07:44

    I am using PHPStorm, which is a sister Project of WebStorm, but it should work the same way.

    You maybe need to add the Library:

    enter image description here

    • File
    • Settings
    • Languages & Frameworks
    • Javascript
    • Librarys

    Add here AngularJS

    If this does not work, you can add them manually:

    enter image description here

    Follow this Steps:

    • File
    • Default Settings
    • Editor
    • Inspection
    • HTML
    • Unknown HTML tag attributes

    To the right you will see in Options "Custom HTML tag attributes". Enter here the attributes you want to allow.

提交回复
热议问题