codemirror-lang-verilog
v1.1.2
Published
Verilog language support for CodeMirror 6
Downloads
47
Maintainers
Readme
Verilog support for CodeMirror 6
This package provides Verilog (IEEE Std 1364-2005) language support for CodeMirror 6. Limited autocompletion features are also available. Note that CodeMirror 6 (and this package by extension) are intended to be used through a browser.
Installation
npm install --save codemirror-lang-verilogRunning the demo
There is a demo that you can start up with npx esmoduleserve ./demo/. This brings up a website at http://localhost:8080 that allows you to test the .
Getting started
Include the language support object as a part of your CodeMirror configuration:
import { verilog } from 'codemirror-lang-verilog';
/** ... **/
new EditorView({
extensions: [
/** ... **/
verilog({
// This object and all of its members are optional.
// Shown values are the defaults
completion: true // Enables the autocompletion features (default)
}),
/** ... **/
]
})Features
The package has the following features:
- 99% complete Verilog-2005 grammar
- libraries were omitted (defined in Annex A, 1.1)
- Automatic indentation.
- Autocompletion for:
- Common
moduledeclarations - Common
alwaysconstructs parameterdeclarationsbegin/endblocks
- Common
Known problems
The following are known problems:
- Library files are not supported.
- Autocompletion indicator images are not present for most completions.
- Keyword completion is very limited.
- There is no completion for defined identifiers.
