html-comment-regex
Regular expression for matching HTML comments
Last updated 8 years ago by stevemao .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install html-comment-regex 
SYNC missed versions from official npm registry.

NPM version Build Status

Regular expression for matching HTML comments

Install

$ npm install --save html-comment-regex

Usage

var htmlCommentRegex = require('html-comment-regex');

htmlCommentRegex.test('<!DOCTYPE html><!--[if lt IE 7]>      <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]--><html lang="en"><head><meta charset="UTF-8"><title>Document</title></head><body></body></html>');
//=> true

htmlCommentRegex.test('<!DOCTYPE html><html lang="en"><head><meta charset="UTF-8"><title>Document</title></head><body></body></html>');
//=> false

License

MIT © Steve Mao

Current Tags

  • 1.1.2                                ...           latest (8 years ago)

5 Versions

  • 1.1.2                                ...           8 years ago
  • 1.1.1                                ...           10 years ago
  • 1.1.0                                ...           11 years ago
  • 1.0.0                                ...           11 years ago
  • 0.0.0                                ...           11 years ago
Maintainers (1)
Downloads
Today 0
This Week 1
This Month 1
Last Day 0
Last Week 0
Last Month 0
Dependencies (0)
None
Dev Dependencies (3)
Dependents (1)

Copyright 2013 - present © cnpmjs.org | Home |