You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by GitBox <gi...@apache.org> on 2022/09/18 12:27:17 UTC

[GitHub] [echarts] linghengqian opened a new issue, #17667: [Bug] The documentation for `EChartsInitOpts` has a type error about height and width

linghengqian opened a new issue, #17667:
URL: https://github.com/apache/echarts/issues/17667

   ### Version
   
   master https://github.com/apache/echarts/commit/c9e9a022d1fc71c78c0f85ebc8d5169c0edc1ab6
   
   ### Link to Minimal Reproduction
   
   Just a documentation error.
   
   ### Steps to Reproduce
   
   - Open https://echarts.apache.org/en/api.html#echarts.init which states that both `width` and `height` are of type `number|string`. We should therefore expect https://github .com/apache/echarts/blob/master/src/core/echarts.ts or https://github.com/apache/echarts/blob/5.3.3/src/core/echarts.ts to be consistent with this documentation.
   
   - ![image](https://user-images.githubusercontent.com/20187731/190901700-3d7847fd-a0a5-4c59-baff-c9a420a577fb.png)
    
   
   ### Current Behavior
   
   - For https://github.com/apache/echarts/blob/master/src/core/echarts.ts and https://github.com/apache/echarts/blob/5.3.3/src/core/echarts.ts , `width` and `height` are both `number`, which means the following paragraph of the document is not reasonable enough.
   ````
   width Specify width explicitly, in pixel. If setting to null/undefined/'auto', width of dom (instance container) will be used.
   height Specify height explicitly, in pixel. If setting to null/undefined/'auto', height of dom (instance container) will be used.
   ````
   - Refer to
   - https://github.com/apache/echarts/blob/5.3.3/src/core/echarts.ts#L322
   - https://github.com/apache/echarts/blob/master/src/core/echarts.ts#L323
   - 
   ![image](https://user-images.githubusercontent.com/20187731/190901858-2fc41d8a-ce88-49ac-a888-55ab1ff768f4.png)
   
   
   ### Expected Behavior
   
   - Updating documentation is expected behavior.
   
   ### Environment
   
   ```markdown
   - OS: Windows 11
   - Browser: 105.0.1343.42
   - Framework: Vue@2
   ```
   
   
   ### Any additional comments?
   
   - I believe most of the people in https://github.com/apache/echarts/issues/10478 get that kind of error simply because they misunderstood the documentation.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[GitHub] [echarts] linghengqian commented on issue #17667: [Bug] The documentation for `EChartsInitOpts` has a type error about height and width

Posted by GitBox <gi...@apache.org>.
linghengqian commented on issue #17667:
URL: https://github.com/apache/echarts/issues/17667#issuecomment-1250598898

   > This issue is labeled with `difficulty: easy`. @linghengqian Would you like to debug it by yourself? This is a quicker way to get your problem fixed. Or you may wait for the community to fix.
   > 
   > Please have a look at [How to debug ECharts](https://github.com/apache/echarts/blob/master/CONTRIBUTING.md#how-to-debug-echarts) if you'd like to give a try. 🤓
   
   - I'm a bit confused about this tag, does this require modifying the document or let's modify the typescript type in [echarts.ts](https://github.com/apache/echarts/blob/5.3.3/src/core/echarts.ts) ?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[GitHub] [echarts] echarts-bot[bot] commented on issue #17667: [Bug] The documentation for `EChartsInitOpts` has a type error about height and width

Posted by GitBox <gi...@apache.org>.
echarts-bot[bot] commented on issue #17667:
URL: https://github.com/apache/echarts/issues/17667#issuecomment-1250597592

   This issue is labeled with `difficulty: easy`.
   @linghengqian Would you like to debug it by yourself? This is a quicker way to get your problem fixed. Or you may wait for the community to fix.
   
   Please have a look at [How to debug ECharts](https://github.com/apache/echarts/blob/master/CONTRIBUTING.md#how-to-debug-echarts) if you'd like to give a try. 🤓


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[GitHub] [echarts] Ovilia closed issue #17667: [Bug] The documentation for `EChartsInitOpts` has a type error about height and width

Posted by GitBox <gi...@apache.org>.
Ovilia closed issue #17667: [Bug] The documentation for `EChartsInitOpts` has a type error about height and width
URL: https://github.com/apache/echarts/issues/17667


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org