@lwc/types
v8.7.0
Published
This package provides type definitions for LWC projects written in TypeScript.
Downloads
10,375
Readme
@lwc/types
This package provides type definitions for LWC projects written in TypeScript.
Usage
[!IMPORTANT] If you use the
lwc
package in your project, then HTML and CSS imports will work without any configuration required.
To enable importing templates or stylesheets, simply import this package once, from anywhere in your project.
// ./types/global.d.ts
import '@lwc/types'
// my-component.ts
import stylesheet from './my-component.css'
import template from './my-component.html'
Module Definitions
This package provides module definitions for HTML and CSS files, so that they can be imported in LWC component script files.