Skip to content

Instantly share code, notes, and snippets.

💭
Svelte x Sapper = <3

Cyrus Besabella besabellacyrus

💭
Svelte x Sapper = <3
View GitHub Profile
@besabellacyrus
besabellacyrus / webpack.config.js
Last active Apr 25, 2020
webpack config for Creating Chrome extensions with React
View webpack.config.js
module.exports = {
entry: "./src/popup.jsx",
resolve: {
extensions: [".js", ".jsx"]
},
module: {
rules: [
{
test: /\.jsx?$/,
exclude: /(node_modules|bower_components)/,
View gist:270981db2f4e835f793b39aab169c79a
// index.html
<div id="chat">
<ul id="message">
<li v-for="message in messages" :key="message.id">{{ message }}</li>
</ul>
<form @submit="send">
<input type="text" v-model="message">
<button>Send</button>
</form>
View gist:374f31b8605006ac740b3aa35157194a
$data['doctor'] = fuel_model(
'doctors',
array(
'find' => 'one',
'where' => array('name' => $name),
'return_method' => 'object'
)
);
then in your view
View gist:28f16853ec04812f2895782497350999
function doctor_profile($slug = NULL)
{
$data['doctor'] = fuel_model(
'doctors',
array(
'find' => 'one',
'where' => array('slug' => $slug),
'return_method' => 'object'
)
);
View mixins media query
$xsmall: 320px;
$small: 544px;
$medium: 767px;
$large: 992px;
$xlarge: 1200px;
$laptopl: 1440px;
$sixteen: 1600px;
@mixin media-breakpoint($media) {
@if $media == xs {
View Doctor_entries_model.php
<?php if (!defined('BASEPATH')) exit('No direct script access allowed');
require_once(FUEL_PATH.'models/Base_module_model.php');
class Doctor_entries_model extends Base_module_model
{
public $has_many = array(
'clinical_focus' => array('clinical_focus_entries_model'),
'specialties' => array('specialty_entries_model'),
'clinics' => array('clinic_entries_model'),
View gist:be417f745081935b9a30
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class MY_Model extends CI_Model {
/**
* The database table to use.
* @var string
*/
public $table_name = '';
You can’t perform that action at this time.