moment / luxon

⏱ A library for working with dates and times in JS
https://moment.github.io/luxon
MIT License
15.23k stars 730 forks source link

Luxon + Typescript 4.9 + Rollup v2 #1448

Open frankli-dev opened 1 year ago

frankli-dev commented 1 year ago

Describe the bug I have a react project based on typescript 4.9 node 18 luxon 2.4.0 types/luxon 2.4.0 rollup 2.70.1 rollup-plugin-ts 3.2.0

And when I build the project, I have the following error

[!] (plugin Typescript) TS1191: An import declaration cannot have modifiers.
node_modules/luxon/src/impl/zoneUtil.js (5:1)

import Zone from "../zone.js";

To Reproduce Please share a minimal code example that triggers the problem:

Actual vs Expected behavior I want to build the project properly not failed with any errors.

Desktop (please complete the following information):

Additional context Add any other context about the problem here.