Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit2ae1739

Browse files
committed
Adding 'How to access global Plotly object code'.closes#92
1 parentd1dd389 commit2ae1739

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

‎FAQ.md‎

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,22 @@ It's possible disable some plotly events returning `false` in its event. Please
1111

1212
Angular uses the`(click)` directive to itself. If we use the`click` name as event alias to`plotly_click` we might get unexpected behaviour from both angular and plotly.js. We believe it is simpler to just avoid using the same name is better.
1313
Please see issue:https://github.com/plotly/angular-plotly.js/issues/63
14+
15+
16+
##How to access global Plotly object code
17+
18+
If you're using`PlotlyModule`, which includes`plotly.js` via commonjs modules, you can access the`Plotly` object via`PlotlyService`. See the example:
19+
20+
```typescript
21+
import {PlotlyService }from'angular-plotly.js';
22+
23+
@Component({
24+
selector:'app-plotly',
25+
template:'...',
26+
})
27+
exportclassAppPlotlyComponent {
28+
constructor(publicplotlyService:PlotlyService) {
29+
const Plotly=plotlyService.getPlotly();
30+
}
31+
}
32+
```

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp