atproto explorer
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

add validation

+31 -3
+3 -1
package.json
··· 14 14 "typescript": "^5.6.3", 15 15 "unocss": "^0.64.0", 16 16 "vite": "^5.4.10", 17 - "vite-plugin-solid": "^2.10.2" 17 + "vite-plugin-solid": "^2.10.2", 18 + "vite-plugin-wasm": "^3.3.0" 18 19 }, 19 20 "dependencies": { 20 21 "@atcute/client": "^2.0.4", 21 22 "@solidjs/router": "^0.15.1", 22 23 "hls.js": "^1.5.17", 24 + "public-transport": "file:pkg/pt.tgz", 23 25 "solid-js": "^1.9.3" 24 26 }, 25 27 "packageManager": "pnpm@9.12.2+sha512.22721b3a11f81661ae1ec68ce1a7b879425a1ca5b991c975b074ac220b187ce56c708fe5db69f4c962c989452eee76c82877f4ee80f474cebd61ee13461b6228"
pkg/pt.tgz

This is a binary file and will not be displayed.

+21
pnpm-lock.yaml
··· 17 17 hls.js: 18 18 specifier: ^1.5.17 19 19 version: 1.5.17 20 + public-transport: 21 + specifier: file:pkg/pt.tgz 22 + version: file:pkg/pt.tgz 20 23 solid-js: 21 24 specifier: ^1.9.3 22 25 version: 1.9.3 ··· 39 42 vite-plugin-solid: 40 43 specifier: ^2.10.2 41 44 version: 2.10.2(solid-js@1.9.3)(vite@5.4.10(@types/node@22.8.1)) 45 + vite-plugin-wasm: 46 + specifier: ^3.3.0 47 + version: 3.3.0(vite@5.4.10(@types/node@22.8.1)) 42 48 43 49 packages: 44 50 ··· 1011 1017 engines: {node: '>=14'} 1012 1018 hasBin: true 1013 1019 1020 + public-transport@file:pkg/pt.tgz: 1021 + resolution: {integrity: sha512-f4xFcUOg64Y4D6c5cEV4FDly5mYn7dlUo8WoPJlfdhF09NioxYvmjCPz/chTfoLNtea3v3fs3UDtxclOhXFLyw==, tarball: file:pkg/pt.tgz} 1022 + version: 0.1.0 1023 + 1014 1024 readdirp@3.6.0: 1015 1025 resolution: {integrity: sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==} 1016 1026 engines: {node: '>=8.10.0'} ··· 1118 1128 '@testing-library/jest-dom': 1119 1129 optional: true 1120 1130 1131 + vite-plugin-wasm@3.3.0: 1132 + resolution: {integrity: sha512-tVhz6w+W9MVsOCHzxo6SSMSswCeIw4HTrXEi6qL3IRzATl83jl09JVO1djBqPSwfjgnpVHNLYcaMbaDX5WB/pg==} 1133 + peerDependencies: 1134 + vite: ^2 || ^3 || ^4 || ^5 1135 + 1121 1136 vite@5.4.10: 1122 1137 resolution: {integrity: sha512-1hvaPshuPUtxeQ0hsVH3Mud0ZanOLwVTneA1EgbAM5LhaZEqyPWGRQ7BtaMvUrTDeEaC8pxtj6a6jku3x4z6SQ==} 1123 1138 engines: {node: ^18.0.0 || >=20.0.0} ··· 2062 2077 2063 2078 prettier@3.3.3: {} 2064 2079 2080 + public-transport@file:pkg/pt.tgz: {} 2081 + 2065 2082 readdirp@3.6.0: 2066 2083 dependencies: 2067 2084 picomatch: 2.3.1 ··· 2205 2222 vitefu: 0.2.5(vite@5.4.10(@types/node@22.8.1)) 2206 2223 transitivePeerDependencies: 2207 2224 - supports-color 2225 + 2226 + vite-plugin-wasm@3.3.0(vite@5.4.10(@types/node@22.8.1)): 2227 + dependencies: 2228 + vite: 5.4.10(@types/node@22.8.1) 2208 2229 2209 2230 vite@5.4.10(@types/node@22.8.1): 2210 2231 dependencies:
+5 -1
src/App.tsx
··· 24 24 TbMoonStar, 25 25 TbSun, 26 26 } from "./lib/svg.jsx"; 27 + import { authenticate_post } from "public-transport"; 27 28 28 29 let rpc = new XRPC({ 29 30 handler: new CredentialManager({ service: "https://public.api.bsky.app" }), ··· 115 116 rpc = new XRPC({ handler: new CredentialManager({ service: pds }) }); 116 117 try { 117 118 const res = await getRecord(params.repo, params.collection, params.rkey); 119 + setNotice("Validating..."); 120 + await authenticate_post(res.data.uri, res.data.cid!, res.data.value); 118 121 setRecord(res.data); 119 122 setNotice(""); 120 123 } catch (err: any) { 121 - setNotice(err.message); 124 + if (err.message) setNotice(err.message); 125 + else setNotice(`Invalid Record: ${err}`); 122 126 } 123 127 }); 124 128
+2 -1
vite.config.ts
··· 1 1 import { defineConfig } from "vite"; 2 2 import solidPlugin from "vite-plugin-solid"; 3 + import wasm from "vite-plugin-wasm"; 3 4 import UnoCSS from "unocss/vite"; 4 5 5 6 const SERVER_HOST = "127.0.0.1"; 6 7 const SERVER_PORT = 13213; 7 8 8 9 export default defineConfig({ 9 - plugins: [UnoCSS(), solidPlugin()], 10 + plugins: [UnoCSS(), wasm(), solidPlugin()], 10 11 server: { 11 12 host: SERVER_HOST, 12 13 port: SERVER_PORT,