OL3 load source-files for development - openlayers-3

I want to make some changes to ol3 (ol.format.WFS2 and ol.format.CityGML), for querying a WFS 2.0 which returns CityGML.
I cannot find however how I can include the openlayers source files into my dev application.
Currently I use the "make build" and include ol-debug.js but thats quite cumbersome for development..

With the help of bartvde in the comments:
run
npm run debug-server
in the ol3 folder.
This sets up a server at localhost:3000 with a loader.js file which you can reference (http://localhost:3000/loader.js) in your demo development website so that all the source code gets loaded.

Related

Bloodhound html file changes are not affecting in ui

I am working on ui bloodhound changes. I have to remove logo of apache bloodhound and header tabs in the dashboard. I made the changes in bloodhound_theme-> bhtheme-> templates-> bloodhound_theme.html, this location file but no changes have been made in ui. after running the server. I checked in the google i didnt get any material regarding it. If anyone knows the way to make a changes in bloodhound ui manually please guide me.
Thanks.
Bloodhound is built on Trac, so most of the Trac documentation applies.
You can modify aspects of the header using configuration options, so modifying a template may not be necessary. See also this documentation.
To modify templates you should follow the instructions TracInterfaceCustomization. In short, you should put a copy of the template in the Environment templates directory.
Keep in mind for any modifications to js and css files, particularly if you followed the installation instructions to install Bloodhound: you'll need to re-run the deploy command to extract static assets to the location from which they are served.
$ trac-admin /opt/bloodhound/environments/main/ deploy /opt/bloodhound/environments/main/site

Where is the default login page for the spring security core plugin?

I have installed the spring security core plugin. I need to modify the login page to look like my existing website. I have searched the entire project and cannot find it. I am running grails 2.4 and spring-security-core:2.0-RC5. Where can this pesky little file be? Can someone who is not a complete greenhorn help a fellow out?
As #Abs points out, the file is at target/work/plugins/spring-security-core-2.0-RC5/grails-app/views/login/auth.gsp but you shouldn't edit plugin files. Other developers on your team won't have access to the modified files and if you delete the target directory you'll lose your changes since the target directory is only a temporary work location.
Instead, copy the file to the same relative location in your application and make changes there. Create grails-app/views/login and copy the file there and make whatever changes you want.
This technique works for most plugin files, not just GSPs. The compilation order and classpath are configured such that application files and classes override plugin files if they're in the same location/package.
You can find the default login page here
targt->work->plugins->spring-security-core-2.0-RC5->grails-app->views->login>auth.gsp

dart2js and dart2dart on build

I am trying to build but I have this situation
Files in bin are server files and don't need to be compiled to js.
Server files us async/await while client files don't. The server is run with the --enable-async VM option.
Client files should be treeshaked/minified JS.
Client files should ALSO be treeshaked/minified (if possible) to Dart.
Currently I include this in my pubspec.yaml
- $dart2js:
$exclude: bin
because I get an error for using async on the server. If I include the async_await transformer I get even more errors (in fact I had to role back to using then on the client).
The real question is how to get efficient server and client dart files, and get efficient client js files out of the build process.
You can use snapshots for server side code. This packs everything into one file and speeds up app startup.
See https://www.dartlang.org/articles/snapshots/ for more details.
I don't have an answer for the other points.

Why running the generated Angular index.html without Grunt shows an empty page?

I generated an Angular app and when I run grunt server it works (it shows the default page) but when I browse the files and double click index.html I get an empty page (except for the grey background).
Why is that? Isn't it just JS/CSS/HTML?
Depending on your setup some files usually need conversion- for instance your styles may well be in compass or SASS and need to be converted to regular css. Grunt handles all the various conversions you need (as well as launching the static page server).
Check out your console error log in the browser and I'll bet you'll see some "Failed to load resource" errors- for instance the css file may well not be there (when you're trying to run index.html directly).
By the way, you can run:
grunt build
This will create a new directory "dist" with everything converted and ready for distribution- sounds like this might be what you're looking for.

Web.config in open source repository

I am creating web application in C# using ASP.NET MVC and I am using MSSQL server installed on my machine.
Also I wanted to publish application as open source project, and run it on production server.
Should I add web.config file to source code repository? If i should, how I should track "open source version" (pointing on MsSQL installed on localhost) and production version (pointing on my hosting of web.config (I am using Mercurial).
The recommended way to do this is as follows:
Create a copy of the public version of the file you'd like people to use as a starting point, and name it something other than the actual usable file. In your case, it could be web.config.template. Make sure the file would be usable if you just renamed it.
Instruct Mercurial to ignore the actual file, ie. web.config
If possible, make the build process figure out if the actual file is present, and if not, make a copy from the template file into the actual file
If step 3 is not possible, a batch file to make the actual file is the next best thing, or simple instructions on how to make it.
This ensures that:
There is a simple way of getting the actual configuration file
You can edit your local actual configuration file without worrying about committing it (it is ignored)
If step 3 was possible, this is largely transparent unless you need to make modifications to the file
Step 3 can be handled with a pre-build event for your project, something like:
if not exist web.config copy web.config.template web.config
You could commit a generic version to your repository, probably on the initial load only (so that the project will build for those who don't know how to create their own), and then add an ignore rule later so that you can add your connection strings and whatnot.

Resources