Our Community Managers used to run our 100+ buildings with google spreadsheets. Giving them one mobile place to manage our members and the day to day sales process has been huge. We were able to have an entire team onboarded to the SpaceStation Mobile codebase in a matter of days, which really speaks to the power of React Native.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
https://twitter.com/_chenglou | |
https://twitter.com/React_Rocks | |
https://twitter.com/ryanflorence | |
https://twitter.com/leeb | |
https://twitter.com/Vjeux | |
https://twitter.com/reactjs | |
https://twitter.com/acdlite | |
https://twitter.com/ReactEurope | |
https://twitter.com/dan_abramov |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const arr1 = [1,2,3]; | |
console.log("arr1 BEFORE PUSH: ", arr1); | |
arr1.push(4); | |
console.log("arr2 AFTER PUSH", arr1); | |
const a1 = [1,2,3]; | |
console.log("a1 BEFORE CONCAT: ", a1); | |
const a2 = a1.concat([4,5,6]); // [ ...a1, 4,5,6 ] | |
console.log("a1 AFTER CONCAT: ", a1); | |
console.log("a2 AFTER CONCAT: ", a2); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import style from '../typography/typography.scss'; | |
class Paragraph extends React.Component { | |
render() { | |
return ( | |
<p className={style.para}>{this.props.children}</p> | |
); | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
info = { | |
email: email, | |
name: name, | |
date: Date.today.strftime("%Y-%d-%m"), #"2014-01-29" | |
customerId: Random.rand(11), | |
lat: current_location[:latitude].to_s, | |
lon: current_location[:longitude].to_s, | |
location_uuid: location_uuid | |
}.to_json |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Set up gems listed in the Gemfile. | |
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__) | |
require 'bundler/setup' if File.exist?(ENV['BUNDLE_GEMFILE']) | |
require 'rails/commands/server' | |
module Rails | |
class Server | |
def default_options | |
if Rails.env.development? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# routes.rb | |
devise_for :users, :path => '', :path_names => {:sign_in => 'login', :sign_out => 'logout'}, :controllers => { :registrations => 'registrations', :sessions => 'sessions' } | |
# registrations_controller.rb | |
class RegistrationsController < Devise::RegistrationsController | |
def create | |
if the token is present? | |
resource.user_group_id = #usergroupid |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Item < ActiveRecord::Base | |
has_many :user_group_items | |
has_many :user_groups, through: :user_group_items | |
end | |
class UserGroup < ActiveRecord::Base | |
has_many :user_group_items | |
has_many :items, through: :user_group_items | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<% articles.each_slice(4) do |four_articles| %> | |
<div class="row"> | |
<% four_articles.each do |article| %> | |
<%= render 'garments/article', article: article, garment: @garment %> | |
<% end %> | |
</div> | |
<% end %> |