0.0.28 • Published 6 years ago
antlr4-autosuggest v0.0.28
JavaScript autosuggest engine for ANTLR4 grammars
Oran Epelbaum
Getting the antlr-autosuggest JavaScript Module
npm install --save antlr4-autosuggest
Example
// Load the lexer and parser modules generated by antlr4
const lexerModule = require('./myGrammarLexer');
const parserModule = require('./myGrammarParser');
// Create an autosuggester, providing it with the lexer and parser classes
const autosuggest = require('antlr4-autosuggest');
const autosuggester = autosuggest.autosuggester(lexerModule.myGrammarLexer, parserModule.myGrammarParser);
// Suggest completions for the string "ABC"
let suggestions = autosuggester.autosuggest("ABC");
How It Works
See explanation in the Java project.
Building
- Clone the antlr-autosuggest-js repository.
- Install Node and NPM (tested with 8)
- Run the command
npm test
.
Credits
Written by Oran Epelbaum at Intigua. When starting to write this, studied the following blog posts (though much has changed since):
0.0.28
6 years ago
0.0.27
6 years ago
0.0.23
6 years ago
0.0.22
6 years ago
0.0.21
6 years ago
0.0.20
6 years ago
0.0.19
6 years ago
0.0.18
6 years ago
0.0.17
6 years ago
0.0.16
6 years ago
0.0.14
6 years ago
0.0.13
6 years ago
0.0.12
6 years ago
0.0.10
6 years ago
0.0.8
6 years ago
0.0.7
6 years ago
0.0.6
6 years ago
0.0.5
6 years ago
0.0.4
6 years ago
0.0.3
6 years ago
0.0.2
6 years ago
0.0.1
6 years ago