Fix the devtools example of how to run an app

This commit is contained in:
Dave Pearson
2022-11-17 10:39:43 +00:00
parent 29a891724b
commit 5f4a44c6c6

View File

@@ -25,7 +25,7 @@ textual run my_app.py
The `run` sub-command will first look for a `App` instance called `app` in the global scope of your Python file. If there is no `app`, it will create an instance of the first `App` class it finds and run that.
Alternatively, you can add the name of an `App` instance or class after a colon to run a specific app in the Python file. Here's an example:
Alternatively, you can add the name of an `App` instance or class after a colon to run a specific app in the Python file. Here's an example:
```bash
textual run my_app.py:alternative_app
@@ -119,6 +119,6 @@ class LogApp(App):
self.log(self.tree)
if __name__ == "__main__":
LogApp.run()
LogApp().run()
```