Weex Language Support is a official tools to code highlight, automatic completion,lint and other functions in IDEA, WebStorm or the others IDEs.
You can install and use this plugin on the following IDEs on any operating system: IntelliJ IDEA Ultimate, PhpStorm, WebStorm, PyCharm, RubyMine, AppCode, CLion, Gogland, Rider
Just searching the Weex Language Support
in plugin repo to install, next you need restart IDE to enable it.
Open Preferences -> Other Settings -> Weex language support
to configuration plugin
LATEST
, it means always using the latest versionnode_modules
directory in current project and npm root will be automatically included, you do not need to add them hereCustom rules are included in a json file, the root node of the json file is an array, each element in the array corresponds to a label in the DSL. Let's take the example of the loading>
tag:
{ "tag": "loading", //tag name, not null "attrs": [ //attributes of tag, can be null { "name": "display", //attribute name, not null "valuePattern": null, //pattern expression to check the attribute value, can be null "valueEnum": [ //attribute value enumeration, can be null "show", "hide" ], "valueType": "var", //type of attribute value, must be var or function "since": 0, //which version the attribute is added to sdk, such as 0.11 "weexOnly": false //whether the attribute is available only in 1.0 syntax, default is false } ], "events": [ //events list, can be null { "name": "loading", //event name, not null "since": 0 //which version the event is added to sdk } ], "parents": [ //The tag is allowed to be a child of which tags, null means no restrictions "list", "scroller" ], "childes": [ //which tags are allowed as their own child tags, null means no restrictions "text", "image", "loading-indicator" ], "document": "/references/components/loading.html" //document link }
Please commiting Issues and Pull Requests into the weex-language-support project