This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <template> | |
| <div class="home"> | |
| <h1>Masonite's blog</h1> | |
| <Blogs /> | |
| </div> | |
| </template> | |
| <script lang="ts"> | |
| import { Component, Vue } from "vue-property-decorator"; | |
| import Blogs from "@/components/Blogs.vue"; // @ is an alias to /src |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <template> | |
| <div class="hello"> | |
| TBD | |
| </div> | |
| </template> | |
| <script lang="ts"> | |
| import { Component, Prop, Vue } from "vue-property-decorator"; | |
| @Component |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <template> | |
| <div id="app"> | |
| <router-view /> | |
| </div> | |
| </template> | |
| <style lang="scss"> | |
| #app { | |
| font-family: "Avenir", Helvetica, Arial, sans-serif; | |
| -webkit-font-smoothing: antialiased; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """A BlogController Module.""" | |
| from masonite.request import Request | |
| from masonite.view import View | |
| from masonite.controllers import Controller | |
| from app.Blog import Blog | |
| class BlogController(Controller): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from orator.orm import Factory | |
| from app.Blog import Blog | |
| from app.User import User | |
| import random | |
| factory = Factory() | |
| def users_factory(faker): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """Base Database Seeder Module.""" | |
| from orator.seeds import Seeder | |
| from databases.seeds.blog_table_seeder import BlogTableSeeder | |
| from .user_table_seeder import UserTableSeeder | |
| class DatabaseSeeder(Seeder): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from orator.seeds import Seeder | |
| from app.Blog import Blog | |
| from config.factories import factory | |
| class BlogTableSeeder(Seeder): | |
| def run(self): | |
| """ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """Blog Model.""" | |
| from config.database import Model | |
| from orator.orm import belongs_to | |
| class Blog(Model): | |
| """Blog Model.""" | |
| __table__ = 'blogs' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from orator.migrations import Migration | |
| class CreateBlogsTable(Migration): | |
| def up(self): | |
| """ | |
| Run the migrations. | |
| """ | |
| with self.schema.create('blogs') as table: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <div class='wrapper'> | |
| <div class='first'> | |
| <a href='https://www.dreamed.ai'>Dreamed Diabetes</a> | |
| </div> | |
| <div class='second'> | |
| <a href='https://www.dreamed.ai'>Dreamed Diabetes</a> | |
| </div> | |
| </div> |