total-typescript / ts-reset

A 'CSS reset' for TypeScript, improving types for common JavaScript API's
https://www.totaltypescript.com/ts-reset
MIT License
7.74k stars 117 forks source link

Importing specific rules doesn't work as documented #169

Closed SuperKXT closed 10 months ago

SuperKXT commented 10 months ago

The documentation says to import the rules directly like so:

import '@total-typescript/ts-reset/dom';

This however does not seem to work. I need to import it from the dist directory:

import '@total-typescript/ts-reset/dist/dom';
mattpocock commented 10 months ago

@SuperKXT What's your moduleResolution in tsconfig.json? It should be NodeNext or Bundler.

SuperKXT commented 10 months ago

Ah, right. I've been meaning to update the tsconfig file for this project. Thank you.

Changing to Bundler breaks the types for vite-plugin-eslint, which is annoying.