Add description of src attribute to py-script (#1136)

* Added description of src attribute to py-script

* Description for py-script src attribute

* resolved mistake of raised by pre-commit

* Update docs/reference/elements/py-script.md

---------

Co-authored-by: Fábio Rosado <hello@fabiorosado.dev>
This commit is contained in:
Kd-Here
2023-03-06 18:09:55 +05:30
committed by GitHub
parent 6bcbbfb085
commit 71d24a445e

View File

@@ -6,7 +6,7 @@ The `<py-script>` element lets you execute multi-line Python scripts both inline
| attribute | type | default | description |
|-----------|--------|---------|------------------------------|
| **src** | url | | Url of a python source file. |
| **src** | url | | You don't need to add long python code in py-script, you can provide url of the python source file in the py-script tag with the `src` attribute. When a Python file is referred with the `src` attribute it is executed, and then added to the namespace where it was referred. |
| **output**| string | | The id of a DOM element to route `sys.stdout` and `stderr` to, in addition to sending it to the `<py-terminal>`|
| **stderr**| string | | The id of a DOM element to route just `sys.stderr` to, in addition to sending it to the `<py-terminal>`|