sql-highlight
sql-highlight copied to clipboard
A simple and lightweight SQL syntax highlighting library written in pure JavaScript
This fixes the "special" segments to include some missing multi-character operators from https://www.w3schools.com/sql/sql_operators.asp and other sites. It also expands the "special" segment to match any single character that doesn't match...
Bumps [semantic-release](https://github.com/semantic-release/semantic-release) from 23.0.6 to 23.0.8. Release notes Sourced from semantic-release's releases. v23.0.8 23.0.8 (2024-04-09) Bug Fixes deps: rename read-pkg-up -> read-package-up (4980cba) deps: rename read-pkg-up -> read-package-up (#3249) (95a8b9e)...
Bumps [eslint-plugin-jest](https://github.com/jest-community/eslint-plugin-jest) from 27.6.3 to 28.3.0. Release notes Sourced from eslint-plugin-jest's releases. v28.3.0 28.3.0 (2024-04-27) Features prefer importing jest globals for specific types (#1568) (c464ae3) v28.2.0 28.2.0 (2024-04-06) Features support...
Bumps [eslint-plugin-n](https://github.com/eslint-community/eslint-plugin-n) from 16.6.2 to 17.3.1. Release notes Sourced from eslint-plugin-n's releases. Release 17.3.1 Revert "fix: unsupported-features/node-builtins-modules range compare" (#254) (caecf3e) v17.3.0 17.3.0 (2024-04-24) 🌟 Features More es-syntax deprecations (#249)...
There are multiple multi-character operators in SQL such as `>=`, ` { expect(getSegments('AGE >= 45')) .toStrictEqual([ { name: 'identifier', content: 'AGE' }, { name: 'whitespace', content: ' ' } {...
Just looking at the code I think there is a bug here: https://github.com/scriptcoded/sql-highlight/blob/909c361424255f5af2a5e87b96dcd9e93e61123d/lib/index.js#L42C21-L42C21 This only matches litteral periods `.`. I assume that you meant to match any character `/(?.+?)/`. Without...
**Describe the bug** ```sql insert into "brands" ("name") values ('Aston Martin') returning "id", "name" ``` In this example `returning` keyword is not in keywords list and is considered as `identifier`....
I've added some missing keywords I stumbled across.
Bumps [semantic-release](https://github.com/semantic-release/semantic-release) from 23.0.6 to 23.1.1. Release notes Sourced from semantic-release's releases. v23.1.1 23.1.1 (2024-05-10) Bug Fixes deps: update dependency execa to v9 (#3296) (73bcd0b) v23.1.0 23.1.0 (2024-05-10) Features add...
Bumps [eslint-plugin-n](https://github.com/eslint-community/eslint-plugin-n) from 16.6.2 to 17.6.0. Release notes Sourced from eslint-plugin-n's releases. v17.6.0 17.6.0 (2024-05-10) 🌟 Features Add support for ignoring experimental features (#269) (c046376) 📚 Documentation add maintenance info...