Skip to content

Commit 9a90468

Browse files
authored
chore: release 1.5.0 (#165)
* feat: support configurable deployment basepath (#158) * fix: next/jest does not support import.meta (#162)
1 parent 56ebed2 commit 9a90468

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+2022
-1523
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@ node_modules
22
dist
33
.DS_Store
44
.vscode
5+
.vercel

apps/nextjs/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
"dependencies": {
1313
"@vercel/analytics": "workspace:*",
1414
"next": "14.1.0",
15-
"react": "18.2.0",
16-
"react-dom": "18.2.0"
15+
"react": "^18.3.1",
16+
"react-dom": "^18.3.1"
1717
},
1818
"devDependencies": {
1919
"@playwright/test": "1.35.1",

apps/remix/.eslintrc.cjs

Lines changed: 0 additions & 4 deletions
This file was deleted.

apps/remix/.gitignore

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
node_modules
22

3+
/.cache
34
/build
4-
/public/build
55
.env
6-
.cache

apps/remix/README.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,16 @@
11
# Remix Vercel Web Analytics Test
2+
3+
## Setup
4+
5+
This application was created with the following commands:
6+
7+
- `cd apps`
8+
- `pnpx create-remix@latest remix` (answers: no git, no dependencies installation)
9+
- `cd remix`
10+
- TODO
11+
- edit package.json to add `"@vercel/analytics": "workspace:*"`
12+
- `pnpm i`
13+
14+
## Usage
15+
16+
Start it with `pnpm -F remix dev` and browse to [http://localhost:5173](http://localhost:5173)

apps/remix/app/root.tsx

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,13 @@
1-
import { cssBundleHref } from '@remix-run/css-bundle';
2-
import type { LinksFunction } from '@remix-run/node';
31
import {
42
Links,
5-
LiveReload,
63
Meta,
74
Outlet,
85
Scripts,
96
ScrollRestoration,
107
} from '@remix-run/react';
118
import { Analytics } from '@vercel/analytics/remix';
129

13-
export const links: LinksFunction = () => [
14-
...(cssBundleHref ? [{ rel: 'stylesheet', href: cssBundleHref }] : []),
15-
];
16-
17-
export default function App() {
10+
export function Layout({ children }: { children: React.ReactNode }) {
1811
return (
1912
<html lang="en">
2013
<head>
@@ -25,11 +18,14 @@ export default function App() {
2518
</head>
2619
<body>
2720
<Analytics />
28-
<Outlet />
21+
{children}
2922
<ScrollRestoration />
3023
<Scripts />
31-
<LiveReload />
3224
</body>
3325
</html>
3426
);
3527
}
28+
29+
export default function App() {
30+
return <Outlet />;
31+
}

apps/remix/app/routes/_index.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
import { json } from '@vercel/remix';
2-
import { Form, Link, useActionData } from '@remix-run/react';
1+
import { Form, json, Link, useActionData } from '@remix-run/react';
32
import { track } from '@vercel/analytics/server';
43

54
export const action = async () => {

apps/remix/app/routes/blog.$slug.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import { json, type LoaderFunctionArgs } from '@remix-run/node';
22
import { Link, useLoaderData } from '@remix-run/react';
3-
import { track } from '@vercel/analytics';
43

54
export const loader = async ({ params }: LoaderFunctionArgs) => {
65
return json({ slug: params.slug });
@@ -11,7 +10,7 @@ export default function BlogPage() {
1110
return (
1211
<div>
1312
<h1>Blog</h1>
14-
<p>We don't talk about {slug}</p>
13+
<p>We don&apos;t talk about {slug}</p>
1514
<br />
1615
<Link to="/">Back</Link>
1716
</div>

apps/remix/package.json

Lines changed: 18 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,35 @@
11
{
22
"name": "remix",
33
"private": true,
4+
"sideEffects": false,
45
"type": "module",
56
"scripts": {
6-
"build": "remix build",
7-
"dev": "remix dev --manual",
8-
"start": "remix-serve ./build/index.js",
7+
"build": "remix vite:build",
8+
"dev": "remix vite:dev",
9+
"start": "remix-serve ./build/server/index.js",
910
"typecheck": "tsc"
1011
},
1112
"dependencies": {
12-
"@remix-run/css-bundle": "^2.5.0",
13-
"@remix-run/node": "^2.5.0",
14-
"@remix-run/react": "^2.5.0",
15-
"@remix-run/serve": "^2.5.0",
16-
"@remix-run/server-runtime": "^2.5.0",
13+
"@remix-run/node": "latest",
14+
"@remix-run/react": "latest",
15+
"@remix-run/serve": "latest",
1716
"@vercel/analytics": "workspace:*",
18-
"@vercel/remix": "2.5.0",
19-
"isbot": "^3.6.3",
17+
"isbot": "^4.1.0",
2018
"react": "^18.2.0",
2119
"react-dom": "^18.2.0"
2220
},
2321
"devDependencies": {
24-
"@remix-run/dev": "^2.5.0",
25-
"@remix-run/eslint-config": "^2.5.0",
26-
"@types/react": "^18.0.25",
27-
"@types/react-dom": "^18.0.8",
28-
"eslint": "^8.56.0",
29-
"typescript": "^5.3.3"
22+
"@remix-run/dev": "latest",
23+
"@types/react": "^18.2.20",
24+
"@types/react-dom": "^18.2.7",
25+
"autoprefixer": "^10.4.19",
26+
"postcss": "^8.4.38",
27+
"tailwindcss": "^3.4.4",
28+
"typescript": "^5.1.6",
29+
"vite": "^5.1.0",
30+
"vite-tsconfig-paths": "^4.2.1"
3031
},
3132
"engines": {
32-
"node": ">=18"
33+
"node": ">=20.0.0"
3334
}
3435
}

apps/remix/remix.config.js

Lines changed: 0 additions & 5 deletions
This file was deleted.

0 commit comments

Comments
 (0)