Skip to content

Additions Plotly.js Type Definition - #15379

Merged
sandersn merged 7 commits into
DefinitelyTyped:masterfrom
chrisgervang:patch-2
Mar 27, 2017
Merged

sandersn merged 7 commits into
DefinitelyTyped:masterfrom
chrisgervang:patch-2

Conversation

@chrisgervang

@chrisgervang chrisgervang commented Mar 25, 2017 •

Copy link
Copy Markdown
Contributor

Hey there! I've seen many folks (#15343, #7202, plotly/plotly.js#28), wanting a better defintion file for Plotly for a long time, so I spent a few hours reading through the plotly source code to put together a more substantial d.ts. This has been tested pretty heavily at my work, and we shipped quite a few Plotly graphs written in TS using this definition file.

Now, it isn't complete unfortunately, as there are tons and tons of graphs and components in plotly. This adds 2D scatter data plots (one of their most common plots), the plotly config, and most of the plotly layout.

  • Make your PR against the master branch.
  • Use a meaningful title for the pull request. Include the name of the package modified.
  • Test the change in your own code. (Compile and run.)
  • Follow the advice from the readme.
  • Avoid common mistakes.
  • Run tsc without errors.
  • Run npm run lint package-name if a tslint.json is present.

Select one of these and delete the others:

If changing an existing definition:

  • Provide a URL to documentation or source code which provides context for the suggested changes: <>
  • Increase the version number in the header if appropriate.
  • If you are making substantial changes, consider adding a tslint.json containing { "extends": "../tslint.json" }.

@dt-bot

dt-bot commented Mar 25, 2017

Copy link
Copy Markdown
Member

types/plotly.js/index.d.ts

to author (@martinduparc). Could you review this PR?
👍 or 👎?

Checklist

  • pass the Travis CI test?

@chrisgervang

Copy link
Copy Markdown
Contributor Author

Can someone help me out here? I'm not sure how to fix the linter error. no-single-declare-module File has only 1 module declaration — write it as an external module.

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

Successfully merging this pull request may close these issues.

4 participants