Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Ruby > Razor (C) Sharp scripting...

Reply
Thread Tools

Razor (C) Sharp scripting...

 
 
SwarmShepherd
Guest
Posts: n/a
 
      09-09-2011

<!-- Single statement block. -->
@{ var theMonth = DateTime.Now.Month; }
<p>The numeric value of the current month: @theMonth</p>


<!-- Multi-statement block. -->
@{
var outsideTemp = 79;
var weatherMessage = "Hello, it is " + outsideTemp + " degrees.";

}
<p>Today's weather: @weatherMessage</p>

================================================== ======

For my client-side work I've been looking around again (IronRuby,
Sinatra, Mono, Rails...) and gosh darned but the most exciting thing
I'm seeing this time around is this new "templating engine" from the
Evil Empire.

note var type for outsideTemp was never declared, note that converting
itself to a String is automatic....

The whole C# / Razor thing seems, somehow, like it might be largely
inspired by Ruby?

Just my humble impression.

It seems a real shame that IronRuby isn't alive and well enough to
kick it up with C# in this particular niche?


Best,

SwarmShepherd aka Thunk

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Bytes Razor starts today at 6am deepaknarula@gmail.com C Programming 1 02-12-2006 09:00 PM
Bytes Razor starts today at 6am deepaknarula@gmail.com C++ 0 02-12-2006 07:40 PM
Bytes RAZOR deepaknarula@gmail.com C++ 1 02-12-2006 05:19 PM
Bytes RAZOR deepaknarula@gmail.com C Programming 0 02-11-2006 06:57 PM
naive body checksum filters (like DCC or Vipul's Razor / Pyzor) versus the Mimail worm? totojepast Computer Security 0 08-06-2003 10:02 PM



Advertisments