Repository Details
Shared by


HelloGitHub Rating
0 ratings
Free•Apache-2.0
Claim
Discuss
Collect
Share
3.3k
Stars
No
Chinese
JavaScript
Language
No
Active
29
Contributors
70
Issues
No
Organization
2.1.7
Latest
460
Forks
Apache-2.0
License
More
体积小、易于使用、支持各种编程语言的语法高亮插件。该项目原理是通过正则过滤关键字,然后进行高亮。代码:
```javascript
// JS关键字判断
Rainbow.extend('javascript', [
/**
* matches $. or $(
*/
{
name: 'selector',
pattern: /\$(?=\.|\()/g
},
{
name: 'support',
pattern: /\b(window|document)\b/g
}
...
```
Included in:
Vol.35
Comments
Rating:
No comments yet