Skip to content

Commit 7ab02c4

Browse files
Merge pull request #37 from storyblok/feat/updating-framework
updating framework
2 parents 3000bf3 + d1deb8f commit 7ab02c4

File tree

3 files changed

+26
-27
lines changed

3 files changed

+26
-27
lines changed

README.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@
66
<p align="center">A CLI to quickly start a project with your favorite framework, already set up with <a href="http://www.storyblok.com?utm_source=github.com&utm_medium=readme&utm_campaign=create-storyblok-app" target="_blank">Storyblok</a>, Headless CMS.</p> <br />
77
<p>Supports
88
<a href="https://nextjs.org/" target="_blank">Next.js</a>,
9-
<a href="https://nuxtjs.org/" target="_blank">Nuxt.js (2 & 3)</a>,
10-
<a href="https://www.gatsbyjs.com/" target="_blank">Gatsby.js</a>,
11-
<a href="https://vuejs.org/" target="_blank">Vue.js</a>,
12-
<a href="https://reactjs.org/" target="_blank">React.js</a>,
9+
<a href="https://nuxtjs.org/" target="_blank">Nuxt</a>,
10+
<a href="https://www.gatsbyjs.com/" target="_blank">Gatsby</a>,
11+
<a href="https://vuejs.org/" target="_blank">Vue</a>,
12+
<a href="https://reactjs.org/" target="_blank">React</a>,
1313
<a href="https://astro.build/" target="_blank">Astro</a>,
1414
<a href="https://remix.run/" target="_blank">Remix</a>,
1515
and <a href="https://kit.svelte.dev/" target="_blank">SvelteKit</a></p>

src/commands/default.ts

+4-3
Original file line numberDiff line numberDiff line change
@@ -161,8 +161,9 @@ export default class CreateStoryblokAppCommand extends Command {
161161
submodules: submodules,
162162
})
163163
directoryTempCreated = true
164-
165-
fs.rmSync(`./temp-started/${framework}/.git`, {recursive: true})
164+
try {
165+
fs.rmSync(`./temp-started/${framework}/.git`, {recursive: true})
166+
} catch {}
166167

167168
const readmeContent = `
168169
# Storyblok quick starter project
@@ -237,7 +238,7 @@ In the folder you have some files like:
237238
log('')
238239
log(
239240
chalkSb(
240-
'You need to setup mkcert to use the visual editor in the app: ',
241+
'You need to setup mkcert to use the Visual Editor in the app: ',
241242
),
242243
)
243244
log('')

src/lib/frameworks.ts

+18-20
Original file line numberDiff line numberDiff line change
@@ -31,28 +31,19 @@ export interface Framework {
3131

3232
const frameworks = [
3333
{
34-
name: 'Vue.js',
34+
name: 'Vue',
3535
value: 'vuejs',
3636
start: 'dev',
3737
token: 'd6IKUtAUDiKyAhpJtrLFcwtt',
3838
config: 'src/main.js',
3939
bridge: 'src/pages/Home.vue',
4040
public: 'public',
4141
port: '3000',
42+
tutorialLink: 'https://www.storyblok.com/tp/add-a-headless-CMS-to-vuejs-in-5-minutes',
4243
},
4344
{
44-
name: 'Nuxt.js 2',
45-
value: 'nuxtjs',
46-
start: 'dev',
47-
token: 'd6IKUtAUDiKyAhpJtrLFcwtt',
48-
config: 'nuxt.config.js',
49-
bridge: 'pages/_.vue',
50-
public: 'static',
51-
port: '3000',
52-
},
53-
{
54-
name: 'Nuxt.js 3',
55-
value: 'nuxtjs-3',
45+
name: 'Nuxt',
46+
value: 'nuxt',
5647
start: 'dev-ssl',
5748
token: 'W1vLyxT5rQ15jBpANjnv0gtt',
5849
config: 'nuxt.config.js',
@@ -76,8 +67,8 @@ const frameworks = [
7667
repositoryUrl: 'https://github.com/storyblok/next.js-ultimate-tutorial.git',
7768
},
7869
{
79-
name: 'React.js',
80-
value: 'reactjs',
70+
name: 'React',
71+
value: 'react',
8172
start: 'start',
8273
token: 'W1vLyxT5rQ15jBpANjnv0gtt',
8374
config: 'src/index.js',
@@ -86,16 +77,20 @@ const frameworks = [
8677
port: '3000',
8778
branch: 'master',
8879
repositoryUrl: 'https://github.com/storyblok/storyblok-react-boilerplate.git',
80+
tutorialLink: 'https://www.storyblok.com/tp/headless-cms-react',
8981
},
9082
{
9183
name: 'Remix',
9284
value: 'remix',
9385
start: 'dev',
9486
token: 'd6IKUtAUDiKyAhpJtrLFcwtt',
95-
config: 'app/root.jsx',
96-
bridge: 'app/routes/home.jsx',
87+
config: 'app/root.tsx',
88+
bridge: 'app/routes/$.jsx',
9789
public: 'public',
9890
port: '3000',
91+
repositoryUrl: 'https://github.com/storyblok/remix-ultimate-tutorial',
92+
branch: 'part-1',
93+
tutorialLink: 'https://www.storyblok.com/tp/the-storyblok-remix-ultimate-tutorial',
9994
},
10095
{
10196
name: 'Astro',
@@ -124,15 +119,18 @@ const frameworks = [
124119
tutorialLink: 'https://www.storyblok.com/tp/the-storyblok-sveltekit-ultimate-tutorial',
125120
},
126121
{
127-
name: 'Gatsby.js',
128-
value: 'gatsbyjs',
122+
name: 'Gatsby',
123+
value: 'gatsby',
129124
start: 'start',
130125
token: 'W1vLyxT5rQ15jBpANjnv0gtt',
131126
config: 'gatsby-config.js',
132127
bridge: 'src/pages/index.js',
133128
public: 'static',
134129
port: '8000',
135-
submodules: true,
130+
tutorialLink: 'https://www.storyblok.com/tp/storyblok-gatsby-ultimate-tutorial',
131+
branch: 'part-1',
132+
repositoryUrl: 'https://github.com/storyblok/gatsby-ultimate-tutorial',
133+
136134
},
137135
] as Framework[]
138136

0 commit comments

Comments
 (0)