Giter Club home page Giter Club logo

laracon-livewire-demo's Introduction

InfyOm

Livewire Demo by Mitul Golakiya

This is a demo of Laravel Livewire for the session taken by Mitul Golakiya during Laravel Live India April 2020 Online Meetup.

We built a kind of Support ticket system where you can list the ticket, click the ticket on left side, and it will load all the comments of that ticket in the right sidebar without writing any single piece of Javascript code.

Also, you can search tickets and add new comments to the ticket without leaving a page just like and SPA (Single Page Application).

Demo App Screenshot

Here is the screenshot of demo application.

Demo Application Image

Session Flow

Here is the flow/stuff that was covered during demo.

  1. Basic Project Setup

    • Laravel Application
    • Setup .env
    • Install basic packages
    • Install Livewire
  2. Setup Tickets and Comments

    • Create Migrations
    • Create Models
    • Create TicketController
    • Create Seeders for some initial demo data
    • Setup Layout
    • Setup Tickets List View
    • Setup Comments View
  3. Setup Livewire Setup CSS + Script

  4. Understand Component Structure

    • Create First Component - TicketsWindow
    • Component File + View File
  5. Reactor TicketsWindow Component

    • Move Blade Code to component file
    • Use component in our blade view
    • Pass Data by Component
  6. Create TicketsList Component

    • Move blade code to component file
    • Pass Data to view
  7. Create CommentsList Component

    • Move blade code to component file
    • Pass Data to view
  8. Data Binding

    • Public properties + mount method
    • Reactor components to use public properties
  9. Livewire Actions

    • Add Interactions to Tickets List
    • Handle Ticket Click
    • Make Ticket selected
  10. Livewire Events

    • Render Comments of selected ticket
    • Dispatch Event from Tickets List when ticket selected
    • Listen event in CommentsList component
    • Refresh the comments of selected ticket
  11. Add Comment

    • Add new comment without page refresh
  12. Handle No Ticket Selection

    • If not ticket has been selected then display empty state
  13. Implement Search

    • Define as a model
    • Make search working
    • Handle few bugs of selections
  14. Display Comments Count

Thanks

Thanks to,

Support Us

We have created 14+ Laravel packages and invested a lot of resources into creating these all packages and maintaining them.

You can support us by either sponsoring us or buying one of our paid products. Or help us by spreading the word about us on social platforms via tweets and posts.

Sponsors

Become a sponsor and get your logo on our README on Github with a link to your site.

Backers

Become a backer and get your image on our README on Github with a link to your site.

Buy our Paid Products

InfyChat

You can also check out our other paid products on CodeCanyon.

Follow Us

laracon-livewire-demo's People

Contributors

dependabot[bot] avatar mitulgolakiya avatar ankitinfyom avatar vishalinfyom avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.