fixtures/flight-esm/src/App.js JAVASCRIPT 75 lines View on github.com → Search inside
1import * as React from 'react';23import Button from './Button.js';4import Form from './Form.js';56import {like, greet} from './actions.js';78import {getServerState} from './ServerState.js';910const h = React.createElement;1112export default async function App() {13  const res = await fetch('http://localhost:3001/todos');14  const todos = await res.json();15  return h(16    'html',17    {18      lang: 'en',19    },20    h(21      'head',22      null,23      h('meta', {24        charSet: 'utf-8',25      }),26      h('meta', {27        name: 'viewport',28        content: 'width=device-width, initial-scale=1',29      }),30      h('title', null, 'Flight'),31      h('link', {32        rel: 'stylesheet',33        href: '/src/style.css',34        precedence: 'default',35      })36    ),37    h(38      'body',39      null,40      h(41        'div',42        null,43        h('h1', null, getServerState()),44        h(45          'ul',46          null,47          todos.map(todo =>48            h(49              'li',50              {51                key: todo.id,52              },53              todo.text54            )55          )56        ),57        h(Form, {58          action: greet,59        }),60        h(61          'div',62          null,63          h(64            Button,65            {66              action: like,67            },68            'Like'69          )70        )71      )72    )73  );74}

Findings

✓ No findings reported for this file.

Get this view in your editor

Same data, no extra tab — call code_get_file + code_get_findings over MCP from Claude/Cursor/Copilot.