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

add type declaration file #13

Merged
merged 1 commit into from
Oct 26, 2021
Merged

add type declaration file #13

merged 1 commit into from
Oct 26, 2021

Conversation

kamiazya
Copy link
Member

What was a problem

The lack of type definitions made it difficult to operate plugins from the API.

How this PR fixes the problem

Added a type definition file so that completion etc. can be heard.

Check lists (check x in [ ] of list items)

  • Test passed
  • Coding style (indentation, etc)

Additional Comments (if any)

fix #12

@kamiazya kamiazya added the enhancement New feature or request label Oct 25, 2021
@kamiazya
Copy link
Member Author

@safareli Hi,

As you commented in issue #12, I added the type definition, but can you confirm that the type definition you want is output?

You can check the type by specifying as follows.
(Since there is no built JS file, it doesn't actually work)

"dependencies": {
  ...,
  "prettier-plugin-dot": "ts-graphviz/prettier-plugin-dot#add-type-declaration-file",
  ...
},

If you need an API type definition like the printXxx function, I will consider it, so please tell us what you want to do.

@safareli
Copy link

In terms of typing this is what I was looking for. Thanks!

@kamiazya kamiazya marked this pull request as ready for review October 26, 2021 01:07
@kamiazya kamiazya merged commit 1eb9b78 into main Oct 26, 2021
@kamiazya kamiazya deleted the add-type-declaration-file branch October 26, 2021 01:07
@kamiazya
Copy link
Member Author

@all-contributors please add @safareli for ideas

@allcontributors
Copy link
Contributor

@kamiazya

I've put up a pull request to add @safareli! 🎉

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

Successfully merging this pull request may close these issues.

Add type definitions for typescript
2 participants