()
| 23 | } |
| 24 | |
| 25 | render() { |
| 26 | const { data, error, isFetching, isPending } = this.repo() |
| 27 | |
| 28 | if (isPending) return html`Loading...` |
| 29 | |
| 30 | if (error) return html`An error has occurred: ${error.message}` |
| 31 | |
| 32 | return html` |
| 33 | <h1>${data.name}</h1> |
| 34 | <p>${data.description}</p> |
| 35 | <strong>👀 ${data.subscribers_count}</strong> |
| 36 | <strong>✨ ${data.stargazers_count}</strong> |
| 37 | <strong>🍴 ${data.forks_count}</strong> |
| 38 | <div>${isFetching ? 'Updating...' : ''}</div> |
| 39 | ` |
| 40 | } |
| 41 | } |
| 42 | |
| 43 | class SimpleApp extends LitElement { |
nothing calls this directly
no outgoing calls
no test coverage detected