Skip to content

Instantly share code, notes, and snippets.

View russweas's full-sized avatar
🦀

Russ Weas russweas

🦀
View GitHub Profile
else {
this.viewData[view].funcs_to_call.push(name);
}
module.exports = {
data: function() {
return {
external: {}
};
},
props: [
'app'
],
methods: {
call: function(view, name) {
if(this.viewData[view].ready == true) {
this.viewData[view].model[name]();
}
}
}
ready: function() {
this.app.viewData['analytics-view'].ready = true;
this.app.viewData['analytics-view'].model = this;
}
module.exports = {
data: function() {
return {
external: {}
};
},
props: [
'app'
],
data: {
currentView: 'edit-view',
app: {},
viewData: {
'edit-view': {},
'about-view': {}
}
}
module.exports = {
props: [
'app'
],
template: require('./analytics.template.html')
};
@russweas
russweas / routes.
Created April 16, 2015 02:59
Laravel Lumen CORS
$app->get('user/{id}', function($id) use ($app) {
return response()
->json([
"name" => 'Billy',
'age' => '42'
])
->header('Access-Control-Allow-Origin', '*');
});
@russweas
russweas / Snippets
Created November 16, 2014 22:33
Just the Basics: Google Forms
Form Action: resolvedtdt.com/php%20form
Required Hidden Form Elements:
form - the google id of the google form
redirect - where you want the browser to go after the google form is saved
How to find input names and form name:
1) When editing the Google Form, click underneath "Responses" "Get pre-filled URL"
2) Just hit submit
3) Copy the link