ts-html-plugin

Type checking and code completion for html inside tagged templates like lit-html.

Please use https://www.npmjs.com/package/ts-lit-plugin instead
Last updated a year ago by runebm .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install ts-html-plugin 
SYNC missed versions from official npm registry.

Typescript HTML Plugin

Typescript plugin that adds type checking and code completion for html inside tagged template strings like lit-html.

Downloads per month Dependencies NPM Version Contributors MIT License

Features

  • Attribute type checking.
  • Report missing imports of custom elements.
  • Goto definition for tags and attributes.
  • Code completions for html tags and attributes.
  • Quick info on on hover for tags and attributes.
  • Required attributes not included
  • Auto closing tags.

Install

Visual Studio Code

If you use Visual Studio Code you can simply install the tagged-html extension.

code --install-extension runem.tagged-html

Other

First, install the plugin:

npm install ts-html-plugin -D

Then add a plugins section to your tsconfig.json:

{
  "compilerOptions": {
    "plugins": [
      {
        "name": "ts-html-plugin",
        "flavor": "lit-html"
      }
    ]
  }
}

Roadmap

  • Support for web-components.json
  • Add tests
  • Aria/accessibility mode
  • SVG support
  • CSS support
  • Support "// @ts-ignore"
  • Type check events (onclick, @click, eg.)
  • Type check slots
  • lit-html: Directive type checking support.
  • lit-element: Better support for the @property({}) decorator taking metadata into account.
  • vanilla: Parse custom elements (observedAttributes, eg.)

Current Tags

  • 0.0.23                                ...           latest (a year ago)

22 Versions

  • 0.0.23 [deprecated]           ...           a year ago
  • 0.0.22 [deprecated]           ...           a year ago
  • 0.0.21 [deprecated]           ...           2 years ago
  • 0.0.20 [deprecated]           ...           2 years ago
  • 0.0.19 [deprecated]           ...           2 years ago
  • 0.0.18 [deprecated]           ...           2 years ago
  • 0.0.17 [deprecated]           ...           2 years ago
  • 0.0.15 [deprecated]           ...           2 years ago
  • 0.0.14 [deprecated]           ...           2 years ago
  • 0.0.13 [deprecated]           ...           2 years ago
  • 0.0.12 [deprecated]           ...           2 years ago
  • 0.0.11 [deprecated]           ...           2 years ago
  • 0.0.10 [deprecated]           ...           2 years ago
  • 0.0.9 [deprecated]           ...           2 years ago
  • 0.0.8 [deprecated]           ...           2 years ago
  • 0.0.7 [deprecated]           ...           2 years ago
  • 0.0.6 [deprecated]           ...           2 years ago
  • 0.0.5 [deprecated]           ...           2 years ago
  • 0.0.4 [deprecated]           ...           2 years ago
  • 0.0.3 [deprecated]           ...           2 years ago
  • 0.0.2 [deprecated]           ...           2 years ago
  • 0.0.1 [deprecated]           ...           2 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (4)
Dev Dependencies (8)
Dependents (0)
None

Copyright 2014 - 2017 © taobao.org |