a collection of lightweight TypeScript packages for AT Protocol, the protocol powering Bluesky
atproto bluesky typescript npm
README.md

@atcute/bluesky-search-parser#

tokenizer for Bluesky's search query syntax.

npm install @atcute/bluesky-search-parser

useful for building search UIs that need to parse and manipulate search queries, such as highlighting operators or extracting filter values.

import { tokenize, type Token } from '@atcute/bluesky-search-parser';

const tokens: Token[] = tokenize(`from:me hello "foo bar"`);
// [
//   { type: 'word', value: 'from:me' },
//   { type: 'whitespace', value: ' ' },
//   { type: 'word', value: 'hello' },
//   { type: 'whitespace', value: ' ' },
//   { type: 'quoted', value: '"foo bar"' },
// ]