You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 4, 2024. It is now read-only.
TS has support for generating *.d.ts for js by flags(allowJs and declarations) in version 3.7, however it fails when applied to both the distributed firepad 1.5.10 as well as the latest sources.
node_modules/firepad/dist/firepad.js:14:1 - error TS9005: Declaration emit for this file requires using private name 'Entity'. An explicit type annotation may unblock declaration emit.
14 (function (name, definition, context) {
~
node_modules/firepad/dist/firepad.js:14:1 - error TS9005: Declaration emit for this file requires using private name 'Firepad'. An explicit type annotation may unblock declaration emit.
14 (function (name, definition, context) {
~
node_modules/firepad/dist/firepad.js:14:1 - error TS9005: Declaration emit for this file requires using private name 'Headless'. An explicit type annotation may unblock declaration emit.
14 (function (name, definition, context) {
~
node_modules/firepad/dist/firepad.js:14:1 - error TS9005: Declaration emit for this file requires using private name 'MonacoAdapter'. An explicit type annotation may unblock declaration emit.
14 (function (name, definition, context) {
~
node_modules/firepad/dist/firepad.js:14:1 - error TS9005: Declaration emit for this file requires using private name 'RichTextCodeMirrorAdapter'. An explicit type annotation may unblock declaration emit.
14 (function (name, definition, context) {
~
node_modules/firepad/dist/firepad.js:14:1 - error TS9005: Declaration emit for this file requires using private name 'TextOperation'. An explicit type annotation may unblock declaration emit.
14 (function (name, definition, context) {
~
Found 6 errors.
examples/firepad-userlist.js:1:1 - error TS9005: Declaration emit for this file requires using private name 'FirepadUserList'. An explicit type annotation may unblock declaration emit.
1 var FirepadUserList = (function() {
~~~
lib/monaco-adapter.js:1:1 - error TS9005: Declaration emit for this file requires using private name 'MonacoAdapter'. An explicit type annotation may unblock declaration emit.
1 'use strict';
~~~~~~~~~~~~
Found 2 errors.
The text was updated successfully, but these errors were encountered:
@toasterpic thanks for the suggestion and the detailed information. Firepad is a pretty old library so it doesn't surprise me that it needs some work to be TS-ready. If you or someone else wants to send a PR to add d.ts files (or just fix the errors above) I would be happy to review it.
@toasterpic If your usecase concerns with Monaco Editor, I can offer you to use @hackerrank/firepad for the time being.
It's complete rewrite of the library in TS with modern build system powered by Webpack/ESM, but I am yet to integrate Ace and CodeMirror to and waiting for that to get completed before pulling it upstream.
TS has support for generating *.d.ts for js by flags(allowJs and declarations) in version 3.7, however it fails when applied to both the distributed firepad 1.5.10 as well as the latest sources.
Version info
Firepad: 1.5.10
Test case
tsc --allowJs --declaration --emitDeclarationOnly ./node_modules/firepad/dist/firepad.js
Expected behavior
valid firepad.d.ts created next to firepad.js
Actual behavior
Test case
Actual behavior
The text was updated successfully, but these errors were encountered: