Skip to content

Instantly share code, notes, and snippets.

@afbjorklund
Created April 19, 2026 18:19
Show Gist options
  • Select an option

  • Save afbjorklund/552cf23e41c68a773463ffd6bfcbddd1 to your computer and use it in GitHub Desktop.

Select an option

Save afbjorklund/552cf23e41c68a773463ffd6bfcbddd1 to your computer and use it in GitHub Desktop.
Example of lima-codapi interaction
<html>
<head>
<link rel="stylesheet" href="https://unpkg.com/@antonz/codapi@0.20.0/dist/snippet.css" />
</head>
<body>
<h1>codapi-lima</h1>
<p>This code will run in the "codapi" lima instance (see `limactl list codapi`):</p>
<pre><code>
uname -a
</code></pre>
<codapi-snippet sandbox="ash" editor="basic"></codapi-snippet>
<p>Note that it will run in a new sandbox container, so the `hostname` will vary.</p>
<script src="https://unpkg.com/@antonz/codapi@0.20.0/dist/settings.js"></script>
<codapi-settings url="http://localhost:1313/v1"></codapi-settings>
<script src="https://unpkg.com/@antonz/codapi@0.20.0/dist/snippet.js"></script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment