Unable to access 'getModel' function in typescript
See original GitHub issueVersion
5.2.2
Link to Minimal Reproduction
No response
Steps to Reproduce
- Create any chart
- on the chart finish event . I am trying to access chart.getModel().getComponent(‘grid’)
- So while running the application we are getting below issue
Property ‘getModel’ is private and only accessible within class ‘ECharts’.
Current Behavior
It is working as expected but need to make the getModel function as public
Expected Behavior
It is working as expected but need to make the getModel function as public
Environment
- OS:
- Browser:
- Framework:
Any additional comments?
If any workaround is there to get the component other than getModel function
Issue Analytics
- State:
- Created 2 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Unable to access objects in Typescript - Stack Overflow
If the code is structured as shown above i.e. the sqlConnector variable is defined in the Typescript class, it throws the error. If...
Read more >get Model from sequelize.models[name: string] #81 - GitHub
I just tried to add this to the function getModel but I can't get the types of the selected model. public getModel<T>(modelName: string) ......
Read more >Understanding and using interfaces in TypeScript
How to use interfaces with classes. So far, we've learned how a function implements an interface. Now let's build a class for the...
Read more >Backbone.js
Backbone is an open-source component of DocumentCloud. ... If the model has a validate method, and validation fails, the model will not be...
Read more >Get data from a server - Angular
This function is configured with both the name of the operation that failed and a safe return value. src/app/hero.service.ts content_copy /** * Handle...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
getModel
is not ready to be public yet because it will expose too much internal abstraction. We only suggest using this method when it’s the only workaround to solve the issue and you can accept the missing doc and potential breaking change of this method in the future.You should listen to datazoom event.