Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeScript definitions? #38

Open
danikaze opened this issue Jan 10, 2020 · 7 comments
Open

TypeScript definitions? #38

danikaze opened this issue Jan 10, 2020 · 7 comments

Comments

@danikaze
Copy link

Is there any way to use @types/blessed with neo-blessed?

@danikaze
Copy link
Author

If using webpack, this can be done leaving

import * as blessed from 'blessed';

and then in webpack use the resolve.alias:

resolve: {
  alias: {
    blessed$: 'neo-blessed',
  },
},

but still... shouldn't this project have it's own definitions? since not everyone is using webpack, and if the library evolves, some new types might be needed...

@KaKi87
Copy link

KaKi87 commented May 9, 2020

Hello,

I'm using JetBrains IntelliJ to code, and I can't find any way to use blessed's typings for neo-blessed so the autocompletion feature is down.

So, +1 for this.

Thanks

@cdaringe
Copy link

cdaringe commented Jun 6, 2020

i've copied blessed's typings and swapped declare module "blessed" with declare module "neo-blessed"--works for now. would like to get them into this repo tho

@BobFrankston
Copy link

I robocopy'ed blessed to neo-blessed in @types and just updated package.json. Since this is a drop-in replacement simply copying @types/blessed to @types/neo-blessed should work but I don't have the confidence to do an official install but since it's simple, I'd encourage others to do so.

@dustinlacewell
Copy link

Hope this gets resolved.

@moonrailgun
Copy link

Is any update for this issue?

I have a local resolution for that.

  • First, install @types/blessed
  • Next, create this file in root: types/neo-blessed/index.d.ts
  • Finally, put declare like below:
    declare module 'neo-blessed' {
      export * from 'blessed';
    }
    

@KaKi87
Copy link

KaKi87 commented Nov 26, 2021

Yes, although it won't contain any change that neo-blessed could have made that doesn't match blessed.

However, after doing a quick look on Useful Forks, I see that @zach-is-my-name is merging other forks, and may be trying to create a super-fork ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants