http://github.com/wharsojo/w2tags/tree
Work: SKYEIGHT (S8)
➢



At-Work: monorails/NET 2.0
➢



Outside-Work: ruby/javascript
➢
●Markup (Haml like) Language
●Patern Builder

●Development Tools

●A GEM

●a ...

●
PRINCIPLES:
Should be Beautiful
Should be DRY
Should be well-indented
Structure should be clear
PRINCIPLES:
Should be Beautiful
Should be DRY
Should be well-indented
Structure should be clear
1




1



2   2
Markup Tags now:
Beautiful
DRY
well-indented
clear
What I need:
a Patern on view in Development
Fast View on Production
keep'n something..
COMMANDS
MACRO TAGS
MACRO END-TAGS
HOT MACRO PATERN
SHORT-CUT TAGS of “DIV”
SHORT-CUT NEXT-TAGS
COMMANDS
     Include HOT(!hot!)
     Include Partial(!inc!)
COMMANDS
     Include HOT(!hot!)
     Include Partial(!inc!)
MACRO TAGS
begin with “%” and it can combine with:
 One css selector of ID(#)
 Multiple css selector of Class(.)
 Costume ...
MACRO END-TAGS



      - ,/
        to pop-all end of tags

      - ~/
        to pop n-tags, depend on
        how many ...
HOT MACRO PATERN
        A defined patern of W2TAGS inside
        HOT files, it can be like a TAGS:
        begin with
  ...
HOT MACRO PATERN
        Inside hot there some vars like:
        - $0 .. $9 for parameter.
        - name id class
      ...
HOT MACRO PATERN
        Inside hot there some vars like:
        - $0 .. $9 for parameter.
        - name id class
      ...
HOT MACRO PATERN
        Inside hot there some vars like:
        - $0 .. $9 for parameter.
        - name id class
      ...
SHORT-CUT TAGS of “DIV”

  Short cut to DIV begin with css selector of
   ID(#)
   Class(.)


        W2TAGS example:

   ...
SHORT-CUT NEXT-TAGS
Command line
Dev View in Rails
Dev View in Merb
W2Tags Is Haml In Erb
W2Tags Is Haml In Erb
W2Tags Is Haml In Erb
W2Tags Is Haml In Erb
Upcoming SlideShare
Loading in …5
×

W2Tags Is Haml In Erb

3,163 views

Published on

w2tags, its a way to tags!

0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
3,163
On SlideShare
0
From Embeds
0
Number of Embeds
920
Actions
Shares
0
Downloads
15
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide

W2Tags Is Haml In Erb

  1. 1. http://github.com/wharsojo/w2tags/tree
  2. 2. Work: SKYEIGHT (S8) ➢ At-Work: monorails/NET 2.0 ➢ Outside-Work: ruby/javascript ➢
  3. 3. ●Markup (Haml like) Language ●Patern Builder ●Development Tools ●A GEM ●a ... ●
  4. 4. PRINCIPLES: Should be Beautiful Should be DRY Should be well-indented Structure should be clear
  5. 5. PRINCIPLES: Should be Beautiful Should be DRY Should be well-indented Structure should be clear
  6. 6. 1 1 2 2
  7. 7. Markup Tags now: Beautiful DRY well-indented clear
  8. 8. What I need: a Patern on view in Development Fast View on Production keep'n something..
  9. 9. COMMANDS MACRO TAGS MACRO END-TAGS HOT MACRO PATERN SHORT-CUT TAGS of “DIV” SHORT-CUT NEXT-TAGS
  10. 10. COMMANDS Include HOT(!hot!) Include Partial(!inc!)
  11. 11. COMMANDS Include HOT(!hot!) Include Partial(!inc!)
  12. 12. MACRO TAGS begin with “%” and it can combine with: One css selector of ID(#) Multiple css selector of Class(.) Costume Attribute ({}) Ruby code (=) Ruby string (==) W2TAGS example: Name Attribute (:) %h1 List User <h1>List User</h1> %h2#title List User <h2 id=”title”>List User</h2> %h2#title.blink.light List User <h2 id=”title” class=”blink light”>List User</h2>
  13. 13. MACRO END-TAGS - ,/ to pop-all end of tags - ~/ to pop n-tags, depend on how many tilde (“~”) you put it on.
  14. 14. HOT MACRO PATERN A defined patern of W2TAGS inside HOT files, it can be like a TAGS: begin with >>tag_name W2TAGS macro (it can multi line) !~ (next tags) <</ (end of tags) See sample on the left, using it - just like regular W2TAGS %h1 Contacts - or using “-” -contact Widi Harsojo;.....
  15. 15. HOT MACRO PATERN Inside hot there some vars like: - $0 .. $9 for parameter. - name id class - defined variable
  16. 16. HOT MACRO PATERN Inside hot there some vars like: - $0 .. $9 for parameter. - name id class - defined variable Var from name id class: - $: - $# - $. - *all* - *opt* - *id* - *name* - *class*
  17. 17. HOT MACRO PATERN Inside hot there some vars like: - $0 .. $9 for parameter. - name id class - defined variable Defined variable: - @samevar=.. - &uniqvar=...
  18. 18. SHORT-CUT TAGS of “DIV” Short cut to DIV begin with css selector of ID(#) Class(.) W2TAGS example: #title List User <div id=”title”>List User</div>
  19. 19. SHORT-CUT NEXT-TAGS
  20. 20. Command line Dev View in Rails Dev View in Merb

×