This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| version: '3.8' | |
| services: | |
| mqtt: | |
| image: eclipse-mosquitto:2.0 | |
| restart: unless-stopped | |
| volumes: | |
| - './mosquitto-data:/mosquitto' | |
| ports: | |
| - '1883:1883' | |
| - '9001:9001' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| gsettings set org.gnome.desktop.input-sources show-all-sources true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import type { RequestHandler } from '@sveltejs/kit'; | |
| export const GET = (async ({ platform }) => { | |
| const ps = platform.env.db.prepare('SELECT * from test'); | |
| const data = await ps.first(); | |
| return new Response(data) | |
| }) satisfies RequestHandler; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //currently not working with cloudflare pages due to a bug | |
| import type { NextRequest } from 'next/server' | |
| export default async function handler(req: NextRequest) { | |
| const { searchParams } = new URL(req.url) | |
| const route = searchParams.getAll('route').join('/') | |
| if (req.method === "GET"){ | |
| console.log(process.env.REST_API_URL) |