Skip to content

Commit 439948a

Browse files
dsklikesmwood23
authored andcommitted
update template, add copy-paste, update readme
1 parent e217d5e commit 439948a

3 files changed

Lines changed: 6 additions & 12 deletions

File tree

README.md

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,6 @@ An experimental starter that explores a new way to build applications on Reddit'
1515

1616
> Make sure you have Node 22 downloaded on your machine before running!
1717
18-
```sh
19-
npm install -g devvit
20-
21-
devvit login
22-
```
23-
2418
1. **Create your project from the template**
2519
<br /><img src="https://github.com/user-attachments/assets/a234a6d6-42ff-4188-b5b9-79d7573c9300" width="400" />
2620
2. **Set up your new repo**
@@ -31,9 +25,9 @@ devvit login
3125
5. `npm install`
3226
6. **Make a subreddit**: Make a private subreddit on Reddit.com. This will be where you do your own development. Go to Reddit.com, scroll the left side bar down to communities, and click "Create a community."
3327
7. **Update the name in package.json**: Find the `dev:devvit` command and replace `YOUR_SUBREDDIT_NAME` with the subreddit name you just created.
34-
8. **Update yaml file**: In `devvit.yaml` replace `YOUR_APP_NAME` with the name of your app. This will be shown to users that play your app.
35-
9. **Upload**: Run `npm run deploy` and go through the prompts
36-
10. **Playtest**: Run `npm run dev` to playtest your application in production by going to your subreddit. Create a post using the subreddit menu action called "Word Guesser: New Post".
28+
8. **Upload**: Run `npm run deploy` and go through the prompts
29+
9. **Playtest**: Run `npm run dev` to playtest your application in production by going to your subreddit.
30+
10. **Create Post**: Create a post using the subreddit menu action called "Word Guesser: New Post".
3731

3832
## Commands
3933

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@
77
"scripts": {
88
"build:client": "cd src/client && vite build",
99
"check": "npm run type-check && npm run lint:fix && npm run prettier",
10-
"deploy": "npm run build:client && devvit upload",
10+
"deploy": "npm run build:client && devvit upload --copy-paste",
1111
"dev": "concurrently -p \"[{name}]\" -n \"VITE,DEVVIT,GAME\" -c \"blue,green,magenta\" \"npm run dev:vite\" \"npm run dev:devvit\" \"npm run dev:client\" --restart-tries 2",
1212
"dev:client": "cd src/client && vite build --watch",
1313
"dev:devvit": "devvit playtest YOUR_SUBREDDIT_NAME",
1414
"dev:vite": "cd src/client && vite --port 7474",
1515
"lint": "eslint ./src",
1616
"lint:fix": "eslint --fix ./src",
17-
"login": "devvit login",
17+
"login": "devvit login --copy-paste",
1818
"prettier": "prettier-package-json --write ./package.json && prettier --write .",
1919
"type-check": "tsc --build"
2020
},

src/server/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import express from 'express';
2-
import { createServer } from 'http';
2+
import { createServer } from '@devvit/server';
33

44
import { devvitMiddleware } from './middleware';
55
import { CheckResponse, InitResponse, LetterState } from '../shared/types/game';

0 commit comments

Comments
 (0)