Skip to content

Commit 2f03317

Browse files
author
Niket Pathak
committed
project setup
0 parents  commit 2f03317

Some content is hidden

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

57 files changed

+21349
-0
lines changed

.env.dist

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# This file is a "template" of which env vars need to be defined for your application
2+
# Copy this file to .env file for development, create environment variables when deploying to production
3+
# https://symfony.com/doc/current/best_practices/configuration.html#infrastructure-related-configuration
4+
5+
###> symfony/framework-bundle ###
6+
APP_ENV=dev
7+
APP_SECRET=36e73c05f63bc2875d261e9652ed0d33
8+
#TRUSTED_PROXIES=127.0.0.1,127.0.0.2
9+
#TRUSTED_HOSTS=localhost,example.com
10+
###< symfony/framework-bundle ###
11+
12+
###> symfony/swiftmailer-bundle ###
13+
# For Gmail as a transport, use: "gmail://username:password@localhost"
14+
# For a generic SMTP server, use: "smtp://localhost:25?encryption=&auth_mode="
15+
# Delivery is disabled by default via "null://localhost"
16+
MAILER_URL=null://localhost
17+
###< symfony/swiftmailer-bundle ###
18+
19+
###> doctrine/doctrine-bundle ###
20+
# Format described at http://docs.doctrine-project.org/projects/doctrine-dbal/en/latest/reference/configuration.html#connecting-using-a-url
21+
# For an SQLite database, use: "sqlite:///%kernel.project_dir%/var/data.db"
22+
# Configure your db driver and server_version in config/packages/doctrine.yaml
23+
DATABASE_URL=mysql://db_user:db_password@127.0.0.1:3306/db_name
24+
###< doctrine/doctrine-bundle ###

.gitignore

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
2+
###> symfony/framework-bundle ###
3+
/.env
4+
/public/bundles/
5+
/var/
6+
/vendor/
7+
###< symfony/framework-bundle ###
8+
9+
###> symfony/webpack-encore-pack ###
10+
/node_modules/
11+
/public/build/
12+
npm-debug.log
13+
yarn-error.log
14+
###< symfony/webpack-encore-pack ###
15+
16+
###> symfony/phpunit-bridge ###
17+
.phpunit
18+
/phpunit.xml
19+
###< symfony/phpunit-bridge ###
20+
21+
###> symfony/web-server-bundle ###
22+
/.web-server-pid
23+
###< symfony/web-server-bundle ###

assets/.gitignore

Whitespace-only changes.

assets/css/custom.less

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
/* GKM version 0.1 */
2+
3+
body {
4+
div {
5+
color:black;
6+
}
7+
}

assets/js/app.vue

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
<template>
2+
<div class="container">
3+
<nav class="navbar is-transparent">
4+
<div class="navbar-brand">
5+
<h1>Getting started with Symfony + VueJS</h1>
6+
</div>
7+
<div id="vue-menu" class="navbar-menu">
8+
<div class="navbar-start">
9+
<router-link tag='div' to="/" class="navbar-item">Home</router-link>
10+
<router-link tag='div' to="hello" class="navbar-item">Hello</router-link>
11+
<router-link tag='div' to="notfound" class="navbar-item">Not Found URL</router-link>
12+
</div>
13+
</div>
14+
</nav>
15+
<div>
16+
<router-view></router-view>
17+
</div>
18+
</div>
19+
</template>
20+
21+
<script>
22+
export default {
23+
name: "app"
24+
}
25+
</script>
26+
27+
<style>
28+
.container .navbar-item {
29+
cursor: pointer;
30+
text-decoration: underline;
31+
}
32+
33+
h1 {
34+
color:blue;
35+
}
36+
</style>

assets/js/components/hello.vue

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<template>
2+
<div id="vueApp">
3+
<div id="container">
4+
<div id="welcome">
5+
<h1>Hello Page</h1>
6+
</div>
7+
<div id="status">
8+
<p>
9+
You are now in <b>Hello vue route</b>
10+
</p>
11+
</div>
12+
</div>
13+
</div>
14+
</template>
15+
16+
<script>
17+
export default {
18+
name: "hello"
19+
}
20+
</script>
21+
22+
<style scoped lang="less">
23+
#welcome h1 {
24+
color: green;
25+
}
26+
</style>

assets/js/components/home.vue

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<template>
2+
<div id="vueApp">
3+
<div id="container">
4+
<div id="welcome">
5+
<h1>Home Page</h1>
6+
</div>
7+
<div id="status">
8+
<p>
9+
You are now in <b>Home vue route</b>
10+
</p>
11+
</div>
12+
</div>
13+
</div>
14+
</template>
15+
16+
<script>
17+
export default {
18+
name: "home"
19+
}
20+
</script>
21+
22+
<style scoped>
23+
#status p {
24+
color: green;
25+
}
26+
</style>

assets/js/components/notFound.vue

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
<template>
2+
<section class="hero is-danger">
3+
<div class="hero-body">
4+
<div class="container">
5+
<h1 class="title">
6+
404 Page not found
7+
</h1>
8+
<p class="subtitle">
9+
its just another vue route - you can change the url above to any thing
10+
</p>
11+
</div>
12+
</div>
13+
</section>
14+
</template>
15+
16+
<script>
17+
export default {
18+
name: "notFound"
19+
}
20+
</script>
21+
22+
<style scoped lang="less">
23+
.title {
24+
color: #0000F0;
25+
}
26+
.hero-body {
27+
background-color: gray;
28+
padding: 15px;
29+
.title {
30+
color: white;
31+
}
32+
}
33+
</style>

assets/js/index.js

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
/* GKM version 0.1 */
2+
import Vue from 'vue';
3+
import VueRouter from 'vue-router';
4+
5+
// app specific
6+
import router from './router/'
7+
import app from './app'
8+
9+
Vue.use(VueRouter);
10+
11+
12+
// bootstrap the demo
13+
let demo = new Vue({
14+
el: '#vueApp',
15+
router,
16+
template: '<app/>',
17+
components: { app }
18+
});

assets/js/router/index.js

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
import Router from 'vue-router'
2+
3+
// components
4+
import home from '../components/home'
5+
import hello from '../components/hello'
6+
import notfound from '../components/notFound'
7+
8+
export default new Router({
9+
mode: 'history',
10+
routes: [
11+
{
12+
path: '/',
13+
name: 'homepage',
14+
component: home
15+
},
16+
{
17+
path: '/hello',
18+
name: 'Hello',
19+
component: hello
20+
},
21+
{
22+
path: '*',
23+
name: 'notfound',
24+
component: notfound
25+
}
26+
]
27+
})

0 commit comments

Comments
 (0)