xdan / jodit

Jodit - Best WYSIWYG Editor for You
https://xdsoft.net/jodit/
MIT License
1.71k stars 354 forks source link

Jodit Pro NPM missing Types folder #990

Open cgraves09 opened 1 year ago

cgraves09 commented 1 year ago

Jodit Version: 1.3.40

Browser: OS: Is React App:

Code

// A *self-contained* demonstration of the problem follows...

Expected behavior: Types is included in package Actual behavior: Error for compiling occures. Could not find a declaration file for module 'jodit-pro'. '/workspace/ui-v2/node_modules/jodit-pro/build/jodit.js' implicitly has an 'any' type. Try npm i --save-dev @types/jodit-pro if it exists or add a new declaration (.d.ts) file containing `declare module 'jodit-pro';

xdan commented 1 year ago

Try now please. In beta 2.0.0-beta.12 now types were published

julianpoemp commented 1 year ago

@xdan where can we find a Typescript definition for all supported options for jodit-pro?

xdan commented 1 year ago

https://xdsoft.net/jodit/docs/classes/config.Config.html Hi

julianpoemp commented 1 year ago

@xdan thanks. I dived in the types folder from the 2.0.0-beta.18release and I found out that jodit is installed along with jodit-pro automatically and the JoditPro class extends from the Jodit class. That means both options are the same. So the typings for pro options are actually missing the typings for pro plugin options. Am I correct?

xdan commented 1 year ago

The types are in their respective plugin folders https://www.npmjs.com/package/jodit-pro/v/2.0.0-beta.18?activeTab=code

image