Web Images Videos Maps News Shopping Gmail more »
Recently Visited Groups | Help | Sign in
Google Groups Home
Compiling Views all at once
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  6 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Chadly  
View profile  
 More options Aug 4 2008, 12:51 am
From: Chadly <chadl...@gmail.com>
Date: Sun, 3 Aug 2008 21:51:09 -0700 (PDT)
Local: Mon, Aug 4 2008 12:51 am
Subject: Compiling Views all at once
One thing that I think would be nice would be to have all Spark views
compile at once at application start -- rather than having each view
compiled only when it is requested.  That way, when there is a
compilation error in one of your views, you would know about it as
soon as you ran the site -- since no pages would work until all views
successfully compiled.

This could also open the door for precompilation options for when you
are deploying a site?


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Louis DeJardin  
View profile  
 More options Aug 4 2008, 3:00 am
From: "Louis DeJardin" <louis.dejar...@gmail.com>
Date: Mon, 4 Aug 2008 02:00:52 -0500
Local: Mon, Aug 4 2008 3:00 am
Subject: Re: Compiling Views all at once
Yeah, that would be ideal. I believe pre-generating all of the view cs
files is something nhaml does as well.

But the big question is how do you know what set of view/master
combinations need to be generated? You could have an inventory xml
file list them all, but that seems out of step with "don't repeat
yourself".

Though maybe that could just be the nature of the thing. You have to
name what you want to precompile.

Or instead of an inventory xml file maybe the spark view files could
have a <precompile master="blah"/> element? That way you could spin
through all of the files on startup.

After that you could have a compile-time tool that generates the all
of the view cs files to include in the web project. Or would it be
better to compile a different assembly to contain all of the view
classes rather than assuming they'll be compiled directly into the web
app?

On 8/3/08, Chadly <chadl...@gmail.com> wrote:


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Louis DeJardin  
View profile  
 More options Aug 4 2008, 3:04 am
From: "Louis DeJardin" <louis.dejar...@gmail.com>
Date: Mon, 4 Aug 2008 02:04:53 -0500
Local: Mon, Aug 4 2008 3:04 am
Subject: Re: Compiling Views all at once
Wait - was it nhaml or Ken's AspView that pregenerated views? Maybe both.

On 8/4/08, Louis DeJardin <louis.dejar...@gmail.com> wrote:


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Justin Chase  
View profile  
 More options Aug 4 2008, 9:53 am
From: "Justin Chase" <justin.m.ch...@gmail.com>
Date: Mon, 4 Aug 2008 08:53:46 -0500
Local: Mon, Aug 4 2008 9:53 am
Subject: Re: Compiling Views all at once

You could create a visual studio plugin that installed an
IVsSingleFileGenerator so you can apply it to .spark files. In this case
when they get saved after an edit the single file generator will create them
right then, that file would get saved to your project and compiled along
with your other classes.. You could also use the same plugin to create a
syntax hilighter / intellisense... though intellisense on something like
this would be ridiculously hard.

Also the engine would have to change quite a bit to accommodate that I
suppose.

On Mon, Aug 4, 2008 at 2:04 AM, Louis DeJardin <louis.dejar...@gmail.com>wrote:

--
Justin Chase
http://www.justnbusiness.com

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Chadly  
View profile  
 More options Aug 4 2008, 12:40 pm
From: Chadly <chadl...@gmail.com>
Date: Mon, 4 Aug 2008 09:40:02 -0700 (PDT)
Local: Mon, Aug 4 2008 12:40 pm
Subject: Re: Compiling Views all at once
I don't think specifying the layout files beforehand is a good way to
go.  This would eliminate the possibility of doing things like
dynamically selecting a layout file from the controller (as a way of
implementing skinning on a site for instance).

I think it would make more sense to have the layout view generate a
separate class from the view that is using it.  That way, it wouldn't
be an issue to dynamically mix and match them after they are compiled.

Also, as a personal preference, I would want the views compiled into a
separate assembly rather than have the CS files generated and become
part of the project.

On Aug 4, 2:00 am, "Louis DeJardin" <louis.dejar...@gmail.com> wrote:


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Louis DeJardin  
View profile  
 More options Aug 4 2008, 2:49 pm
From: Louis DeJardin <Louis.DeJar...@gmail.com>
Date: Mon, 4 Aug 2008 11:49:53 -0700 (PDT)
Local: Mon, Aug 4 2008 2:49 pm
Subject: Re: Compiling Views all at once

I wouldn't suggest that it would either control or limit the layouts
that were used with the view - just which combinations were
precompiled. The rest of the framework would function as it stands
except if a precompiled view existed for a particular view descriptor
it wouldn't need to be generated and cached.

I'm not sure it would be possible to split the layout and view
classes. There's a lot they share as class members with macros,
viewdata, all of the context members, etc.

On Aug 4, 5:40 pm, Chadly <chadl...@gmail.com> wrote:


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2009 Google