Architecture

Architecture in Norscode is mainly about responsibility boundaries. Good architecture keeps routing, domain rules, storage and third-party integrations understandable as separate concerns, so the codebase remains easier to change and easier to operate.

Practical layering

A useful default split is: route layer, domain layer, storage layer and integration layer. The goal is not to maximise abstraction. The goal is to stop unrelated concerns from collapsing into the same handlers and helpers.

prosjekt/
  app/
  domain/
  infra/
  integrations/

Why this matters over time

When the structure matches responsibility, tests become easier to place, bugs become easier to localise and teams spend less time arguing about where new code belongs. Architecture is therefore not only a design topic. It is a maintenance and collaboration topic as well.

Continue with contracts or modules if you want the next step down from high-level structure into concrete file and API boundaries.