Skip to content

Commit

Permalink
chore: update dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
rossrobino committed Apr 18, 2024
1 parent fd0be7b commit 60676dc
Show file tree
Hide file tree
Showing 12 changed files with 51 additions and 44 deletions.
Binary file modified docs/bun.lockb
Binary file not shown.
14 changes: 7 additions & 7 deletions docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,17 @@
},
"devDependencies": {
"@tailwindcss/typography": "^0.5.12",
"@types/node": "^20.11.30",
"@types/node": "^20.12.7",
"@vercel/analytics": "^1.2.2",
"autoprefixer": "^10.4.19",
"domco": "../dist/domco",
"drab": "^5.3.6",
"drab": "^5.4.0",
"prettier": "^3.2.5",
"prettier-plugin-tailwindcss": "^0.5.13",
"robino": "^0.1.0",
"prettier-plugin-tailwindcss": "^0.5.14",
"robino": "^0.2.0",
"tailwindcss": "^3.4.3",
"typescript": "^5.4.3",
"uico": "^0.2.2",
"vite": "^5.2.7"
"typescript": "^5.4.5",
"uico": "^0.2.4",
"vite": "^5.2.9"
}
}
4 changes: 2 additions & 2 deletions docs/src/+config.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import type { Config } from "domco";
import { process } from "robino/util/md";
import { processMarkdown } from "robino/util/md";
import fs from "fs/promises";

export const config: Config = {
build: async ({ document }, { params }) => {
params;
const md = await fs.readFile("../README.md", "utf-8");
const { html } = await process(md);
const { html } = await processMarkdown(md);
const article = document.querySelector("article");
if (article) article.innerHTML = html;
},
Expand Down
4 changes: 2 additions & 2 deletions docs/src/docs/learn/+config.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import type { Config } from "domco";
import { process } from "robino/util/md";
import { processMarkdown } from "robino/util/md";
import fs from "node:fs/promises";

export const config: Config = {
build: async ({ document }) => {
const md = await fs.readFile(`src/docs/learn/index.md`, "utf-8");
const { html } = await process(md);
const { html } = await processMarkdown(md);
const article = document.querySelector("article");
if (article) article.innerHTML = html;
},
Expand Down
4 changes: 2 additions & 2 deletions docs/src/docs/modules/+config.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import type { Config } from "domco";
import { process } from "robino/util/md";
import { processMarkdown } from "robino/util/md";
import fs from "node:fs/promises";

export const config: Config = {
build: async ({ document }) => {
const md = await fs.readFile(`../packages/domco/docs/modules.md`, "utf-8");
const { html } = await process(md);
const { html } = await processMarkdown(md);
const article = document.querySelector("article");
if (article) article.innerHTML = html;
},
Expand Down
23 changes: 15 additions & 8 deletions docs/src/test/[slug]/+config.ts
Original file line number Diff line number Diff line change
@@ -1,16 +1,23 @@
// src/posts/[slug]/index.build.ts
import { Config } from "domco";

const params = [
{ slug: "first-post" },
{ slug: "second-post" },
{ slug: "third-post" },
] as const;
/**
* Generates an array of objects with slugs from 1 to n.
* @param count The number of objects to generate.
* @returns An array of objects with slug properties.
*/
const generateSlugs = (count: number) => {
const params = [];
for (let i = 1; i <= count; i++) {
params.push({ slug: `${i}-post` });
}
return params;
};

export const config: Config<typeof params> = {
params,
export const config: Config = {
params: generateSlugs(2),
build: ({ document }, { params }) => {
const h1 = document.querySelector("h1");
if (h1) h1.textContent = params.slug; // "first-post" | "second-post" | "third-post"
if (h1) h1.textContent = params.slug as string;
},
};
Binary file modified packages/create-domco/bun.lockb
Binary file not shown.
8 changes: 4 additions & 4 deletions packages/create-domco/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "create-domco",
"description": "Create a new domco project",
"version": "0.0.38",
"version": "0.0.39",
"type": "module",
"types": "./index.d.ts",
"main": "./index.js",
Expand All @@ -27,11 +27,11 @@
"which-pm-runs": "^1.1.0"
},
"devDependencies": {
"@types/node": "^20.11.20",
"@types/node": "^20.12.7",
"@types/which-pm-runs": "^1.0.2",
"prettier": "^3.2.5",
"robino": "^0.1.0",
"typescript": "^5.3.3"
"robino": "^0.2.0",
"typescript": "^5.4.5"
},
"prettier": "robino/config/prettier"
}
10 changes: 5 additions & 5 deletions packages/create-domco/template/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const domcoVersion = "0.5.4";
const domcoVersion = "0.5.5";

export const getFiles = (options: {
lang: string;
Expand Down Expand Up @@ -26,18 +26,18 @@ export const getFiles = (options: {
}
},
"devDependencies": {
"@types/node": "^20.11.30",
"@types/node": "^20.12.7",
"domco": "^${domcoVersion}",${prettier ? `\n\t\t"prettier": "^3.2.5",` : ""}${
prettier && tailwind
? `\n\t\t"prettier-plugin-tailwindcss": "^0.5.13",`
? `\n\t\t"prettier-plugin-tailwindcss": "^0.5.14",`
: ""
}${
tailwind
? `\n\t\t"tailwindcss": "^3.4.3",\n\t\t"autoprefixer": "^10.4.19",`
: ""
}
"typescript": "^5.3.3",
"vite": "^5.2.7"
"typescript": "^5.4.5",
"vite": "^5.2.9"
}
}
`,
Expand Down
Binary file modified packages/domco/bun.lockb
Binary file not shown.
12 changes: 6 additions & 6 deletions packages/domco/docs/modules.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export const config: Config = {

#### Defined in

[types/index.ts:55](https://github.com/rossrobino/domco/blob/e31f172/packages/domco/types/index.ts#L55)
[types/index.ts:55](https://github.com/rossrobino/domco/blob/fd0be7bff9d3a3f5e06d1741a20d9eab79e187cb/packages/domco/types/index.ts#L55)

___

Expand Down Expand Up @@ -87,7 +87,7 @@ ___

#### Defined in

[types/index.ts:3](https://github.com/rossrobino/domco/blob/e31f172/packages/domco/types/index.ts#L3)
[types/index.ts:3](https://github.com/rossrobino/domco/blob/fd0be7bff9d3a3f5e06d1741a20d9eab79e187cb/packages/domco/types/index.ts#L3)

___

Expand All @@ -112,7 +112,7 @@ Context about the current page to utilize during the build.

#### Defined in

[types/index.ts:16](https://github.com/rossrobino/domco/blob/e31f172/packages/domco/types/index.ts#L16)
[types/index.ts:16](https://github.com/rossrobino/domco/blob/fd0be7bff9d3a3f5e06d1741a20d9eab79e187cb/packages/domco/types/index.ts#L16)

___

Expand All @@ -137,7 +137,7 @@ ___

#### Defined in

[types/index.ts:69](https://github.com/rossrobino/domco/blob/e31f172/packages/domco/types/index.ts#L69)
[types/index.ts:69](https://github.com/rossrobino/domco/blob/fd0be7bff9d3a3f5e06d1741a20d9eab79e187cb/packages/domco/types/index.ts#L69)

___

Expand All @@ -147,7 +147,7 @@ ___

#### Defined in

[types/index.ts:67](https://github.com/rossrobino/domco/blob/e31f172/packages/domco/types/index.ts#L67)
[types/index.ts:67](https://github.com/rossrobino/domco/blob/fd0be7bff9d3a3f5e06d1741a20d9eab79e187cb/packages/domco/types/index.ts#L67)

## Functions

Expand Down Expand Up @@ -188,4 +188,4 @@ export const config: Config = {

#### Defined in

[helpers/addBlocks/index.ts:26](https://github.com/rossrobino/domco/blob/e31f172/packages/domco/helpers/addBlocks/index.ts#L26)
[helpers/addBlocks/index.ts:26](https://github.com/rossrobino/domco/blob/fd0be7bff9d3a3f5e06d1741a20d9eab79e187cb/packages/domco/helpers/addBlocks/index.ts#L26)
16 changes: 8 additions & 8 deletions packages/domco/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "domco",
"description": "Build-Time Rendering Without Templates",
"version": "0.5.4",
"version": "0.5.5",
"type": "module",
"keywords": [
"vite-plugin",
Expand Down Expand Up @@ -39,20 +39,20 @@
"license": "MIT",
"devDependencies": {
"@types/html-minifier-terser": "^7.0.2",
"@types/node": "^20.11.20",
"@types/web": "^0.0.140",
"@types/node": "^20.12.7",
"@types/web": "^0.0.143",
"prettier": "^3.2.5",
"robino": "^0.1.0",
"typedoc": "^0.25.8",
"robino": "^0.2.0",
"typedoc": "^0.25.13",
"typedoc-plugin-markdown": "^3.17.1",
"typescript": "^5.3.3"
"typescript": "^5.4.5"
},
"dependencies": {
"@types/jsdom": "^21.1.6",
"esbuild": "^0.20.1",
"esbuild": "^0.20.2",
"html-minifier-terser": "^7.2.0",
"jsdom": "^24.0.0",
"vite": "^5.1.4"
"vite": "^5.2.9"
},
"prettier": "robino/config/prettier"
}

0 comments on commit 60676dc

Please sign in to comment.