Sample Javascript Viewer

11470
72
05-27-2010 12:26 PM
ChristianSmith
New Contributor III
Does anyone know if the sample viewer team plans to upgrade, change / modify the JS sample viewer in the near future ?

Thanks

Smitty
0 Kudos
72 Replies
AlexeyMokrev
New Contributor
Hello.
I have a similar problem with code 500.
Please tell me in detail how you solved it?
0 Kudos
YusukeNUNOKAWA
New Contributor III
I found the problem in Basic Viewer Template: Internet Explorer freezes when reopening a panel after closing it in web application based on basic viewer template.

The following source code was download in the GitHub page of "Basic Viewer Template".
https://github.com/Esri/basic-viewer-template
This implemention is not good.
Function for closing a panel is called with "href" property, "onclick" property better than it.
<div style="float:right;clear:both;" id="paneCloseBtn"><a title=${close_title} alt=${close_alt} href="JavaScript:hideLeftPanel();"><img src=images/closepanel.png border="0"/></a></div>


I fix it like the following.
<div style="float:right;clear:both;" id="paneCloseBtn" onclick="hideLeftPanel();"><a title=${close_title} alt=${close_alt} href="#"><img src=images/closepanel.png border="0"/></a></div>


In ArcGIS Online, I can't touch it.
Could you please fix it.
0 Kudos
JohnGravois
Frequent Contributor
yusuke,

thanks for finding this fix.  i have submitted a pull request to the repro on your behalf so that the change can be incorporated into the AGOL template in a future update. 

https://github.com/Esri/basic-viewer-template/pull/1

you could even do this yourself next time if you wanted.

thanks again!
0 Kudos
BobbySells
New Contributor II
So we are going from the Flex API, which we have highly customized and invested in, to Javascript.  I couldn't believe there was no sample viewer to get started with and build from there.  I saw Jeff's manatee.org site and instantly see that it resembles flex.  Is there a basic template that has that feel to get started with?
Bobby
0 Kudos
AnthonyGiles
Frequent Contributor
Currently all the talk at the developer summit is about the new web app builder for Javascript. It looks like a pretty neat product and will be out for beta testing at the end of the month. Check out the video:

http://video.esri.com/watch/3211/web-app-builder

Regards

Anthony
0 Kudos
JeffPace
MVP Alum
Bobby,
I got your email, but figured I would reply here.

I would recommend waiting for ESRI's supported viewer this summer.  We are already abandoning that viewer and are moving to a "tablet" first one.

Some musings:

ESRI aggressively is pitching the "one use, one app" philosophy, as seen in the samples.  Need directions, write an app that does directions.  Need parcel info? Write a parcel viewer. 

Good for simple users.  Terrible for both developers and for advanced users.  The problem is there are WAY more simple users

So the whole "modular viewer template" that you can add dozens of widgets to, a desktop replacement as it were, is going away.  At least, its almost actively discouraged.

A few (myself included) of the more veteran javascript developers disagree, any there are many threads discussing it.  Its a philosophy difference that I think will be aggravated by the influx of former flex developers that are used to dropping widgets onto an application to add functionality.

I'm not sure what the answer is, but I know for my user base, they want one app that can do everything.  They don't, ever, want to "do this here, then go here to do that, then over there to do this". 

Our old viewer did this pretty well, but it was heavy weight and not very mobile-friendly.  Our new one (very in development stage) is mobile first, but desktop replacement as the end goal. www.mymanatee.org/gisapps/mobile/mobile/index.html

We will consider ESRI's app when we see it this summer, and see how much we can migrate.  But so far so good in this one. 

Also I apologize if anyone has emailed or PM'd and I didn't reply.  I prefer to keep dialog to the forums where it is to the benefit of everyone.

-Jeff
0 Kudos
BobbySells
New Contributor II
Thanks for the replies Anthony and Jeff.
I agree 100% about one stop shop.  I jumped on Flex as soon as ESRI debuted it and have done a tremendous amount of modification and development.  We made heavy use of the single viewer model with multiple configs that are loaded from a database. 
Jeff-that is why I wondered if there was a base sample to get going with.  I downloaded the basic viewer from github but was interested in continuing with the Flex look and feel.
Bobby
0 Kudos
JeffPace
MVP Alum
I totally agree and understand.

I will happily give you the code, but here are my concerns

1. It is not AMD style.  The original viewer was released at 1.6 and has never been updated.  I have been patching it along, badly.  It functions at 3.4 but I have not tested it past that.  Taking it to AMD style would be a ridiculous amount of work, which is why we deprecated it
2. I have alot of stuff hardcoded into to make it work.  Back in the 1.6 days alot of functionality (like legends, etc..) didnt exist.  We wrote a lot of code to custom include that, and dropped it but didnt always clean up the code afterwards
3. It doesnt work on mobile devices
4. It doesnt work AT ALL on touch devices.  In fact, its a disaster, hence deprecating.
5. There is alot of code in there to make it work on IE6 (which we finally dropped support for last year)
6. Its slow as dirt

Your call.  Our new viewer is way better, and I am excited to see what ESRI comes up with (would be nice to be in a supported environment, so to speak)
0 Kudos
JeffPace
MVP Alum
updated link to our new viewer

www.mymanatee.org/gisapps/mobile/index.html
0 Kudos
GrantHerbert
Occasional Contributor II
updated link to our new viewer

www.mymanatee.org/gisapps/mobile/index.html


Hey Jeff, that looks great! Impressive work.
0 Kudos