eclipse-thingweb / eclipse-thingweb/node-wot

ESLint Warning n/no-missing-import

Open
#1,428 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
192
Forks
100
Avg merge
3d 2h
Merged PRs (30d)
6

Description

With https://github.com/eclipse-thingweb/node-wot/pull/1424 we introduced some *new* eslint warnings.

One warning is `n/no-missing-import`

https://github.com/eclipse-thingweb/node-wot/blob/736f2803f3eceac36919d0455d7713272bbcad46/eslint.config.mjs#L79-L82

Which shows for *normal* imports like

https://github.com/eclipse-thingweb/node-wot/blob/736f2803f3eceac36919d0455d7713272bbcad46/packages/core/src/codecs/base64-codec.ts#L16

Image

To fix it (as the comment above alludes), one needs to change

`import { ContentCodec } from "../content-serdes"; `

to

`import { ContentCodec } from "../content-serdes.js"; `

Do we really want to do that? I think it works but to me, it looks somewhat silly in a TS project to reference JS files?

Opinions?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.