File tree 1 file changed +5
-4
lines changed
1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -19,8 +19,8 @@ Create a new `hello.ps1` with the following content:
19
19
20
20
``` posh
21
21
Import-Module pglet
22
- Connect-PgletPage
23
- Invoke-Pglet "add text value=' Hello, world!'"
22
+ $page = Connect-PgletPage
23
+ $page.Add((Text -Value " Hello, world!"))
24
24
```
25
25
26
26
Run ` hello.ps1 ` in your PowerShell session and in a new browser window you'll get:
@@ -34,8 +34,9 @@ Here is a local page served by an instance of Pglet server started in the backgr
34
34
Add ` -Web ` parameter to ` Connect-PgletPage ` call:
35
35
36
36
``` posh
37
- Connect-PgletPage -Web
38
- Invoke-Pglet "add text value='Hello, world!'"
37
+ Import-Module pglet
38
+ $page = Connect-PgletPage -Web
39
+ $page.Add((Text -Value "Hello, world!"))
39
40
```
40
41
41
42
This time page will be created on [ Pglet hosted service] ( https://pglet.io/docs/pglet-service ) .
You can’t perform that action at this time.
0 commit comments