際際滷

際際滷Share a Scribd company logo
Life on the Edge




http://www.鍖ickr.com/photos/stuckincustoms/3376506512/




                                                              @pwim
                    JA Meetup #1
2006




               @pwim
JA Meetup #1
2006



2008




               @pwim
JA Meetup #1
2006



2008



2009           Heroku




                    @pwim
JA Meetup #1
2006



2008



2009            Heroku



2010           Tokyo Rubyist Meetup



                      @pwim
JA Meetup #1
WEB




               @pwim
JA Meetup #1
20           LT   




                    @pwim
JA Meetup #1
@pwim
JA Meetup #1
1 dyno




                        @pwim
JA Meetup #1
1 dyno




                        @pwim
JA Meetup #1
@pwim
JA Meetup #1
CoffeeScript vs. JavaScript

fill = (container, liquid = "coffee") ->
  "Filling the #{container} with #{liquid}..."




                         @pwim
  JA Meetup #1
CoffeeScript vs. JavaScript

fill = (container, liquid = "coffee") ->
  "Filling the #{container} with #{liquid}..."




var fill;
fill = function(container, liquid) {
   if (liquid == null) {
     liquid = "coffee";
  }
   return "Filling the " + container + " with " + liquid + "...";
};




                         @pwim
  JA Meetup #1
Sass Vs. Css

  $margin: 16px

  .border
    padding: $margin / 2
    margin: $margin / 2

  table.hl
    margin: 2em 0
    td.ln
      text-align: right




                      @pwim
JA Meetup #1
Sass Vs. Css

  $margin: 16px                .border {
                                 padding: 8px;
  .border                        margin: 8px;
    padding: $margin / 2       }
    margin: $margin / 2
                               table.hl {
  table.hl                       margin: 2em 0;
    margin: 2em 0              }
    td.ln
      text-align: right        table.hl td.ln {
                                 text-align: right;
                               }




                      @pwim
JA Meetup #1





               @pwim
JA Meetup #1


        



               @pwim
JA Meetup #1


        

        

               @pwim
JA Meetup #1
Java




                  @pwim
JA Meetup #1
Too
               Java


               UGLY!
                  @pwim
JA Meetup #1
rake assets:precompile




                      @pwim
JA Meetup #1
禽看艶壊稼t
   rake assets:precompile


                Work
                      @pwim
JA Meetup #1
Rails 3.0




               @pwim
JA Meetup #1
Rails 3.0
               Lets
                Try
                @pwim
JA Meetup #1
Gem鍖le


  gem 'rails', '3.0.7'
  gem 'sass'
  gem 'barista'
  group :production do
    gem 'therubyracer', "~> 0.9.0beta7"
  end




                @pwim
JA Meetup #1
con鍖g/initializers/barista_con鍖g.rb



  Barista.configure do |c|
    c.output_root = Rails.root.join(
      "tmp", "coffeescripts")
  end




                    @pwim
JA Meetup #1
con鍖g/initializers/sass.rb
  Sass::Plugin.options[:template_location] =
    'app/stylesheets'
  Sass::Plugin.options[:css_location] =
    'tmp/stylesheets'

  Rails.configuration.middleware.delete(
    'Sass::Plugin::Rack')
  Rails.configuration.middleware.insert_before(
    'Rack::Sendfile', 'Sass::Plugin::Rack')

  Rails.configuration.middleware.insert_before(
    'Rack::Sendfile', 'Rack::Static',
    :urls => ['/stylesheets'],
    :root => "#{Rails.root}/tmp")




                      @pwim
JA Meetup #1
 css/js
 Rails cache-busting strategy   :
  application.css?1323295




                      @pwim
JA Meetup #1
Gem鍖le

  gem 'rails', '3.1.0.rc4'
  gem 'sprockets', '= 2.0.0.beta.10'
  gem 'sass-rails', "~> 3.1.0.rc"
  gem 'coffee-script'
  gem 'uglifier'
  group :production do
    gem 'therubyracer', "~> 0.9.1"
  end




               @pwim
JA Meetup #1
界看稼鍖g/温沿沿鉛庄界温岳庄看稼.姻恢




           config.assets.enabled = true




                    @pwim
JA Meetup #1
con鍖g/environments/production.rb




  config.assets.compress = true
  config.assets.js_compressor = :uglifier




                  @pwim
JA Meetup #1
Rails 3.1


 New Relic
 Dalli (memcache gem)         session
  store



               @pwim
JA Meetup #1
Further Information


 http://www.mobalean.com/blog/2011/06/29/
  using-the-asset-pipeline-under-rails-3-1

 http://www.tokyorubyistmeetup.org/
           7   13



                    @pwim
JA Meetup #1

More Related Content

Life on the Edge

Editor's Notes

  1. \n
  2. \n
  3. \n
  4. \n
  5. \n
  6. \n
  7. \n
  8. \n
  9. \n
  10. \n
  11. \n
  12. \n
  13. \n
  14. \n
  15. \n
  16. \n
  17. \n
  18. \n
  19. \n
  20. \n
  21. \n
  22. \n
  23. \n
  24. \n
  25. \n