Skip to content

Instantly share code, notes, and snippets.

View madhusudhan1234's full-sized avatar

Madhu Sudhan Subedi madhusudhan1234

View GitHub Profile
public function up()
{
Schema::create('users', function (Blueprint $table) {
$table->increments('id');
$table->string('name');
$table->string('email')->unique();
$table->string('address');
$table->timestamp('email_verified_at')->nullable();
$table->string('password');
$table->rememberToken();
<?php
namespace App\Http\Controllers;
use App\Http\Resources\UsersResource;
use App\User;
use Illuminate\Http\Request;
/**
* Class UsersController
<!doctype html>
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="csrf-token" content="{{ csrf_token() }}">
<title>Laravel</title>
<link rel="stylesheet" href="{{ asset('css/app.css') }}"/>
</head>
<body>
<List
itemLayout="vertical"
size="large"
pagination={{
onChange: (page) => {
console.log(page);
},
pageSize: 3,
}}
dataSource={this.state.episodes}
server {
listen 80;
listen [::]:80;
server_name example.dev;
root /var/www/example/public;
index index.php index.html index.htm;
location / {
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="csrf-token" content="{{ csrf_token() }}">
<title>{{ config('app.name', 'Laravel') }}</title>
<link href="/css/app.css" rel="stylesheet">
</head>
<vue-pagination :pagination="users"
@paginate="getUsers()"
:offset="4">
</vue-pagination>
@extends('layouts.app')
@section('content')
<div class="container">
<table class="table table-bordered">
<tr>
<th>Name</th>
<th>Email</th>
<th>Created At</th>
</tr>
<tr v-for="user in users.data">
require('./bootstrap');
import VuePagination from './components/Pagination.vue';
import axios from 'axios';
axios.defaults.headers.common = {
'X-Requested-With': 'XMLHttpRequest',
'X-CSRF-TOKEN': document.querySelector('meta[name="csrf-token"]').getAttribute('content')
};
window.Event = new Vue();
Vue.component('post', {
template: '#post-template',
props: ['title', 'author', 'content'],
created(){
let vm0 = new Vue();
Event.$on('alertData',this.alertData);
},
methods:{