Skip to content

Commit

Permalink
Fix wailsapp#2280; code highlight & minor linter change
Browse files Browse the repository at this point in the history
  • Loading branch information
BuckeyeCoder committed Feb 1, 2023
1 parent e1bd841 commit 44e04c8
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions website/docs/howdoesitwork.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ Wails requires that you pass in an _instance_ of the struct for it to bind it co

In this example, we create a new `App` instance and then add this instance to the `Bind` option in `wails.Run`:

```go {16,24} title="main.go"
```go {17,27} title="main.go"
package main

import (
Expand Down Expand Up @@ -188,7 +188,7 @@ func (a *App) Greet(name string) string {

You may bind as many structs as you like. Just make sure you create an instance of it and pass it in `Bind`:

```go {8-10}
```go {10-12}
//...
err := wails.Run(&options.App{
Title: "Basic Demo",
Expand Down Expand Up @@ -276,7 +276,7 @@ it will be returned to your frontend as a JavaScript class.

:::info Note

Struct fields *must* have a valid `json` tag to be included in the generated TypeScript.
Struct fields _must_ have a valid `json` tag to be included in the generated TypeScript.

Anonymous nested structs are not supported at this time.

Expand Down

0 comments on commit 44e04c8

Please sign in to comment.