# Anchor
click_link 'Save'
# Button
click_button 'awesome'
# Both above
// DONT FORGET TO `yarn add esbuild-loader` !!! | |
// config/webpacker/environment.js | |
const { environment } = require('@rails/webpacker') | |
const { ESBuildPlugin } = require('esbuild-loader') | |
const esBuildUse = [ | |
{ | |
loader: require.resolve('esbuild-loader'), | |
// What you want to compile to, in this case, ES7 |
$black: #22292f; | |
$grey-darkest: #3d4852; | |
$grey-darker: #606f7b; | |
$grey-dark: #8795a1; | |
$grey: #b8c2cc; | |
$grey-light: #dae1e7; | |
$grey-lighter: #f1f5f8; | |
$grey-lightest: #f8fafc; | |
$white: #fff; | |
$red-darkest : #3b0d0c; |
npm install --save-dev @angularclass/hmr |
(function () { | |
'use strict'; | |
angular | |
.module('app') | |
.factory('OfflineInterceptor', ["$q", function ($q) { | |
// queue for saving requests to be sent to the server when connection is down | |
var queue = []; | |
return { |
/* ---------------------------------------------------------------------------------------------------- | |
SCSS Form Reset Helpers - Forked from: https://gist.github.com/anthonyshort/552543 | |
Intended usage: | |
- MIXINS: for very specific use cases, when you dont want to reset absolutly all the forms, very verbose output. | |
- PLACEHOLDER SELECTORS: use as extending classes. Less verbose, more generic overrides. | |
A couple of things to watch out for: |
Form::macro('multiselect', function($name, $list = [], array $selected = [], $options = []) | |
{ | |
$options['name'] = $name; | |
$html = array(); | |
if (is_string($selected)) $selected[$selected] = $selected; | |
//dd($list, $selected); | |
foreach ($list as $value => $display) | |
{ | |
$sel = isset($selected[$value])?' selected="selected"':''; |
<?php | |
require 'tmhOAuth.php'; // Get it from: https://github.com/themattharris/tmhOAuth | |
// Use the data from http://dev.twitter.com/apps to fill out this info | |
// notice the slight name difference in the last two items) | |
$connection = new tmhOAuth(array( | |
'consumer_key' => '', | |
'consumer_secret' => '', | |
'user_token' => '', //access token |
⇐ back to the gist-blog at jrw.fi
Or, 16 cool things you may not have known your stylesheets could do. I'd rather have kept it to a nice round number like 10, but they just kept coming. Sorry.
I've been using SCSS/SASS for most of my styling work since 2009, and I'm a huge fan of Compass (by the great @chriseppstein). It really helped many of us through the darkest cross-browser crap. Even though browsers are increasingly playing nice with CSS, another problem has become very topical: managing the complexity in stylesheets as our in-browser apps get larger and larger. SCSS is an indispensable tool for dealing with this.
This isn't an introduction to the language by a long shot; many things probably won't make sense unless you have some SCSS under your belt already. That said, if you're not yet comfy with the basics, check out the aweso
There's no shortage of good resources for learning laravel. So instead of the usual introductory tutorial were just gonna learn Laravel by building a project from scratch and that's gonna be a User Management System.
I don't know if my definition of a User Management System is correct but here's my idea of what's it's capable of doing:
- Register Roles
- Register Users
- Update Users