kddresearch / KDD-Wiki-NextJS

The new KDD Wiki written with NextJS
Other
2 stars 0 forks source link

Page Categories #20

Closed Legonois closed 3 months ago

Legonois commented 4 months ago

User Story

As an Admin, I want to create and manage categories so that I can organize the directory structure.

Criteria

Tasks

Legonois commented 4 months ago

Category Schema

Criteria

Contains static pages Contains more category objects Implements an ORM (Drizzle ORM)

Legonois commented 3 months ago

ISSUES:

I hate this part because it means I cannot find a solution online AHHHHHHH

Top level awaits in NextJS not working

The generated code contains 'async/await' because this module is using "topLevelAwait".
However, your target environment does not appear to support 'async/await'.
As a result, the code may not run as expected or may cause runtime errors.

been stuck on this for a few hours. I mainly need it in client components. But, turns out you can't have async in client components without a state changer (use effect), so what I am using it for specifically would not work. So, DO NOT USE async at top level in client components without state changes

Legonois commented 3 months ago

When implementing the new secrets retreval system, I thought that it would eventually take longer because these routes would reload the config often. But with the singleton, we look to be good! I visited all the routes and it only did 3 reloads!

Image

I am glad this is working so well