I'd succeeded to support both cjs and esm modules, by publishing js, mjs, d.ts, d.mts files at the same time, through developing custom builder program. However, it can cause duplicated class problem. If a library imports Vector of tstl as CSM and another library also imports Vector class of ESM, two Vector classes being considered as different class.
Therefore, I conclude this experiment as premature and decided to roll back.
However, I will keep the custom builder program for future.
I'd succeeded to support both cjs and esm modules, by publishing
js
,mjs
,d.ts
,d.mts
files at the same time, through developing custom builder program. However, it can cause duplicated class problem. If a library importsVector
oftstl
as CSM and another library also importsVector
class of ESM, twoVector
classes being considered as different class.Therefore, I conclude this experiment as premature and decided to roll back.
However, I will keep the custom builder program for future.