Shy
Shy
HHono
Created by Peтe on 10/9/2024 in #help
JSX not working at all with just "bun add hono"
I don't think it failed, I think you're trying to render a list of objects
14 replies
HHono
Created by Nivek on 10/4/2024 in #help
Bun Monorepo Hono RPC
Honestly my brain just became typescripty…? I can’t exactly understand why but even from the first day I saw it I knew it will probably not work 😅 But anyways looking at the typescript docs https://www.typescriptlang.org/docs/handbook/type-inference.html type inference happens when initializing the variables That’s why hono suggests always doing this practice https://hono.dev/docs/guides/rpc#using-rpc-with-larger-applications
18 replies
HHono
Created by Nivek on 10/4/2024 in #help
Bun Monorepo Hono RPC
but you should do this
import { Hono } from "hono";

const app = new Hono()
.get("/", (c) => {
return c.text("Hello Hono!");
})
.basePath("api").get("/expenses", (c) => {
return c.json({
total: 13034.12,
});
});

export type AppType = typeof app;
export default app;
import { Hono } from "hono";

const app = new Hono()
.get("/", (c) => {
return c.text("Hello Hono!");
})
.basePath("api").get("/expenses", (c) => {
return c.json({
total: 13034.12,
});
});

export type AppType = typeof app;
export default app;
18 replies
HHono
Created by Nivek on 10/4/2024 in #help
Bun Monorepo Hono RPC
you're doing this
18 replies
HHono
Created by Nivek on 10/4/2024 in #help
Bun Monorepo Hono RPC
import { Hono } from "hono";

const app = new Hono();

app.get("/", (c) => {
return c.text("Hello Hono!");
})
.basePath("api").get("/expenses", (c) => {
return c.json({
total: 13034.12,
});
});

export type AppType = typeof app;
export default app;
import { Hono } from "hono";

const app = new Hono();

app.get("/", (c) => {
return c.text("Hello Hono!");
})
.basePath("api").get("/expenses", (c) => {
return c.json({
total: 13034.12,
});
});

export type AppType = typeof app;
export default app;
18 replies
HHono
Created by Nivek on 10/4/2024 in #help
Bun Monorepo Hono RPC
you're not doing correct
18 replies
HHono
Created by Nivek on 10/4/2024 in #help
Bun Monorepo Hono RPC
this is the server index
import { Hono } from "hono";

const app = new Hono()
.get("/", (c) => {
return c.text("Hello Hono!");
})
.basePath("api").get("/expenses", (c) => {
return c.json({
total: 13034.12,
});
});

export type AppType = typeof app;
export default app;
import { Hono } from "hono";

const app = new Hono()
.get("/", (c) => {
return c.text("Hello Hono!");
})
.basePath("api").get("/expenses", (c) => {
return c.json({
total: 13034.12,
});
});

export type AppType = typeof app;
export default app;
18 replies
HHono
Created by Nivek on 10/4/2024 in #help
Bun Monorepo Hono RPC
No description
18 replies
HHono
Created by Nivek on 10/4/2024 in #help
Bun Monorepo Hono RPC
No description
18 replies
HHono
Created by Nivek on 10/4/2024 in #help
Bun Monorepo Hono RPC
No description
18 replies
HHono
Created by Nivek on 10/4/2024 in #help
Bun Monorepo Hono RPC
I cloned and installed then only changed this
18 replies
HHono
Created by Nivek on 10/4/2024 in #help
Bun Monorepo Hono RPC
it did work for me?
18 replies
HHono
Created by Nivek on 10/4/2024 in #help
Bun Monorepo Hono RPC
I'll clone it and try
18 replies
HHono
Created by Nivek on 10/4/2024 in #help
Bun Monorepo Hono RPC
try chaining like this
const app = new Hono()
.get("/", (c) => {
return c.text("Hello Hono!");
})
.basePath("api").get("/expenses", (c) => {
return c.json({
total: 13034.12,
});
});
const app = new Hono()
.get("/", (c) => {
return c.text("Hello Hono!");
})
.basePath("api").get("/expenses", (c) => {
return c.json({
total: 13034.12,
});
});
18 replies