ezolenko / rollup-plugin-typescript2

Rollup plugin for typescript with compiler errors.
MIT License
819 stars 71 forks source link

Alias not working with fonts? #438

Closed ko22009 closed 1 year ago

ko22009 commented 1 year ago

import bold from 'assets/fonts/OpenSans/OpenSans-Bold.woff2';

alias assets doesn't work.

agilgur5 commented 1 year ago

entirely removed issue template...

Please don't remove the issue template, it's there for a reason.

Please do be respectful to maintainers, the vast majority of which are unpaid volunteers. To be explicit, a one line issue that removes the entire issue template is not respectful.

aliases

alias assets doesn't work.

"Aliases" are not truly supported by TypeScript itself, please see #201 for significant details about this.

fonts

This plugin doesn't work with non ts files

It is a TS plugin, it's only meant to handle TS files. tsc itself does not handle non-TS files.

If you're trying to import a font into your library, you need a separate plugin for that. TS also needs declarations for that, as it does for all non-TS asset files, see also #160