RocketChat / Rocket.Chat.Apps-compiler

The Rocket.Chat apps compiler.
MIT License
5 stars 11 forks source link

Fix in 0.3.1 causes import bug with module which has only 1 export #41

Open cuonghuunguyen opened 3 years ago

cuonghuunguyen commented 3 years ago

The fix in 0.3.1 cannot fit every case. It causes an error when packaging my App at: https://github.com/cuonghuunguyen/Rocket-Chat-Livechat-Clean

// constants/scheduled-jobs.ts
export const JobID = {
    CLEAN_ROOMS: 'CLEAN_ROOMS',
};

```ts
// scheduled-jobs/clean-rooms.ts
import {JobID} from '../constants/scheduled-jobs';
JobID.CLEAN_ROOMS
^^^ cannot read property CLEAN_ROOMS of undefined

The logs of the Apps CLI is not good so I had to spend hours debugging it 😓 Packaging and Deploying with my own (private) App Packager works fine

Shailesh351 commented 3 years ago

I can confirm this issue. https://open.rocket.chat/channel/rocketchat-apps?msg=ElRicDQZB8WRRfSxH