Skip to content

MVP of Complete rewrite - #30

Open
bristermitten wants to merge 26 commits into
masterfrom
complete-rewrite
Open

MVP of Complete rewrite#30
bristermitten wants to merge 26 commits into
masterfrom
complete-rewrite

Conversation

@bristermitten

Copy link
Copy Markdown
Member

we have:

  • a home page
  • a mostly working learning resources impl
  • a rules page

unlike before, this finally matches the actual design and colour schemes of the server!

CopilotAI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR is a ground-up rewrite of the website, migrating from a hand-rolled Elm SPA build/deploy setup to an Elm Land–based app with a new layout/theme and updated tooling (Bun, Nix flake, GitHub Pages deploy).

Changes:

  • Replaced the old Elm SPA routing/views with Elm Land pages/layouts and shared model/message structure.
  • Added the new Home, Rules, and Learning Resources pages (including resource detail view) using the new theming.
  • Reworked build/deploy tooling: Bun-based scripts, Tailwind module generation, Nix flake dev shell, and GitHub Pages workflows.

Reviewed changes

Copilot reviewed 44 out of 62 changed files in this pull request and generated 9 comments.

Show a summary per file
FileDescription
tsconfig.jsonAdds TypeScript config (used for repo scripts/tooling).
tailwind.config.tsNew Tailwind configuration (colors/fonts/content).
tailwind.config.jsRemoves legacy Tailwind config.
static/index.htmlRemoves legacy static entrypoint HTML.
static/devden-logo.svgAdds new logo asset.
static/devden-banner.svgAdds new banner asset.
static/custom.cssRemoves legacy custom font CSS.
static/base.cssAdds base stylesheet (Tailwind directives, fonts, CSS variables).
src/Views/ServicesRules.elmRemoves legacy view module.
src/Views/Rules.elmRemoves legacy view module.
src/Views/Home.elmRemoves legacy view module.
src/Views/Blank.elmRemoves legacy blank view module.
src/View.elmIntroduces Elm Land view adapter using Html.Styled.
src/Theming.elmAdds shared theming helpers (gradients/fonts/card shell).
src/Shared/Msg.elmAdds shared message type (learning index fetch, retry, etc.).
src/Shared/Model.elmAdds shared model for learning database status.
src/Shared.elmAdds Elm Land shared init/update/subscriptions to fetch learning DB.
src/Route.elmRemoves legacy custom route parser/stringifier.
src/Redirects.elmSimplifies redirect constants to Discord/GitHub only.
src/Pages/Rules.elmNew Rules page (data-driven sections and rendering).
src/Pages/Learning/Resource_.elmNew Learning topic detail page with sidebar + resource cards.
src/Pages/Learning.elmNew Learning directory page with search + grouping.
src/Pages/Home_.elmNew Home page (banner + CTA + floating social links).
src/Page.elmRemoves legacy page wrapper/background/navbar implementation.
src/OpenApi/Common.elmAdds shared OpenAPI/HTTP decoder utilities and error types.
src/Main.elmRemoves legacy Browser.application entrypoint.
src/LearningResources/Types.elmAdds generated types for LearningResources database schema.
src/LearningResources/Json.elmAdds generated JSON encoders/decoders for LearningResources schema.
src/LearningResources/Emojis.elmAdds emoji fallback mapping logic for topics.
src/LearningResources.elmAdds small helper functions for filtering metadata/resources.
src/Layouts/Global.elmAdds global layout (navbar, page shell).
src/Effect.elmAdds Elm Land effect system (routing, shared messages, cmd wrapping).
src/Api.elmAdds API helper to fetch LearningResources DB from jsdelivr.
README.MDUpdates local dev/formatting instructions and TODO list.
postcss.config.jsReplaces legacy PostCSS config with new plugin-based config.
package.jsonSwitches to Bun/Elm Land toolchain and updates dependencies/scripts.
nginx.confRemoves legacy nginx deployment config.
main.cssRemoves legacy Tailwind entry CSS file.
LICENSERemoves legacy MIT license file.
generate-elm-types.tsAdds script to generate Elm types from LearningResources OpenAPI schema.
flake.nixReplaces dev env with flake-parts + treefmt + Bun/Elm tooling.
flake.lockUpdates lockfile for new flake inputs.
elm.jsonUpdates Elm dependencies and source directories for Elm Land + gen output.
elm-land.jsonAdds Elm Land app configuration (meta, stylesheet link, scripts).
DockerfileRemoves legacy Docker build/deploy pipeline.
.yarnrc.ymlRemoves Yarn config (moving away from Yarn).
.gitignoreUpdates ignores for Elm Land, Bun, Nix/direnv, generated Tailwind modules.
.github/workflows/deploy.ymlReplaces Docker registry flow with GitHub Pages build + deploy.
.github/workflows/ci.ymlAdds CI build/lint workflow using Bun + Elm Land + Tailwind module generation.
.envrcUpdates direnv flake invocation.
.dockerignoreRemoves Docker ignore file (Docker removed).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment threadsrc/Api.elm
Comment on lines +5 to +8
import Json.Decode as Json
import LearningResources.Json as LearningResources
import LearningResources.Types as LearningResources
import Yaml.Decode
- name: Build and push Docker image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
- run: bun install --frozen-lockfile

Comment threadpostcss.config.js
}; No newline at end of file
export default {
plugins: {
"@tailwindcss/postcss": {},
Comment threadelm-land.json
"link": [
{
"rel": "stylesheet",
"href": "/base.css"
Comment threadREADME.MD Outdated
Comment threadgenerate-elm-types.ts
Comment on lines +1 to +11
import {
quicktype,
InputData,
JSONSchemaInput,
FetchingJSONSchemaStore
} from "quicktype-core";
import path from "path";
import fs from "fs"
import { $ } from "bun";

const SCHEMA_URL = "https://cdn.jsdelivr.net/gh/TheDeveloperDen/LearningResources@cb31652/openapi.schema.json";
Comment threadpackage.json
Comment on lines 20 to 25
"dependencies": {
"postcss-loader": "^6.1.1",
"serve": "^12.0.1",
"watch": "^1.0.2",
"yarn": "^1.22.15"
"@tailwindcss/postcss": "^4.3.0",
"elm-tailwind-modules": "^0.5.0",
"postcss": "^8.4.0",
"tailwindcss": "^3.4.0"
}
Comment threadsrc/Shared.elm
Comment on lines +15 to +18
import Api
import Dict
import Effect exposing (Effect)
import Json.Decode
Comment threadsrc/Shared/Model.elm
Comment on lines +8 to +10
import Dict exposing (Dict)
import Http
import LearningResources.Types as LearningResources
bristermittenand others added 3 commits May 14, 2026 19:21

CopilotAI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 44 out of 62 changed files in this pull request and generated 18 comments.

Comment threadsrc/Theming.elm
Comment on lines +6 to +7
import Tailwind.Theme as Tw
import Tailwind.Utilities as Tw
Comment threadsrc/Pages/Rules.elm
Comment on lines +12 to +13
import Tailwind.Theme as Tw
import Tailwind.Utilities as Tw
Comment on lines +18 to +19
import Tailwind.Theme as Tw
import Tailwind.Utilities as Tw
Comment on lines +16 to +17
import Tailwind.Theme as Tw
import Tailwind.Utilities as Tw
import Route exposing (Route)
import Route.Path
import Shared
import Tailwind.Theme as Tw
Comment on lines +5 to +7
import Html.Styled as Html exposing (Html, div, span, text)
import Html.Styled.Attributes as Attr exposing (css, href, target)
import Layouts
Comment threadsrc/Shared.elm
Comment on lines +15 to +18
import Api
import Dict
import Effect exposing (Effect)
import Json.Decode
Comment threadsrc/Shared/Model.elm
Comment on lines +8 to +10
import Dict exposing (Dict)
import Http
import LearningResources.Types as LearningResources
Comment threadsrc/Pages/Home_.elm
Comment on lines +4 to +6
import Effect exposing (Effect)
import Html.Styled as Html exposing (Html, a, div, fieldset, h1, h2, i, img, legend, p, text)
import Html.Styled.Attributes as Attr exposing (css, href, target)
Comment threadsrc/Pages/Home_.elm
Comment on lines +13 to +16
import Tailwind.Breakpoints as Breakpoints
import Tailwind.Theme as Tw
import Tailwind.Utilities as Tw
import Theming
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@bristermitten