Skip to content

Instantly share code, notes, and snippets.

@defunctzombie
defunctzombie / browser.md
Last active April 10, 2024 17:45
browser field spec for package.json
openapi: 3.1.0
info:
title: Foxglove API
version: "1"
x-logo:
url: https://foxglove.dev/images/logo-icon-round.png
description: |
Api documentation for foxglove services.
openapi: 3.0.0
info:
title: Sample API
description: Optional multiline or single-line description in [CommonMark](http://commonmark.org/help/) or HTML.
version: 0.1.9
servers:
- url: http://api.example.com/v1
description: Optional server description, e.g. Main (production) server
- url: http://staging-api.example.com
description: Optional server description, e.g. Internal staging server for testing
// The ./types module provides helper types for your Input events and messages.
import { Input, Message } from "./types";
// Your node can output well-known message types, any of your custom message types, or
// complete custom message types.
//
// Use `Message` to access your data source types or well-known types:
// type Twist = Message<"geometry_msgs/Twist">;
//
// Conventionally, it's common to make a _type alias_ for your node's output type
{
"header": {
"stamp": {
"sec": 123,
"nsec": 123,
},
"frame_id": "",
"seq": 0,
},
"status": [{
@defunctzombie
defunctzombie / README.md
Last active January 25, 2022 18:49
foxglove/studio/gh-2718
yarn
yarn start
const worker = new Worker(new URL("./worker.js", import.meta.url));
const input = document.createElement("input");
input.type = "file";
document.body.appendChild(input);
input.onchange = (ev) => {
const file = ev.target.files[0];
worker.postMessage({ file });
};
"syntax": "proto3",
"root": {
"name": "",
"fullName": "",
"syntaxType": "ProtoRoot",
"nested": {
"Person": {
"name": "Person",
"fullName": ".Person",
{
"action": {
"type": "SAVE_PANEL_CONFIGS",
"payload": {
"configs": [
{
"id": "onboarding.welcome!24okipi",
"config": {}
}
]
const HID = require("node-hid");
const vendorId = 4617;
const productId = 17185;
async function main() {
const device = new HID.HID(vendorId, productId);
device.on("error", (err) => {
console.error(err);