-
Notifications
You must be signed in to change notification settings - Fork 132
Contributing
Mapstraction is for JavaScript developers, so many users are capable of making improvements to the code. The project was moved to github to make contributing easy, just join github, fork the project, and send a pull request containing your contributions:
- If you don’t have a github account, get one: Getting started with github
- Fork the mxn project as outlined in Forking a project.
- Create a branch to contain your contributions, and send a pull request from it.
If you’re not familiar with git, the Git User’s Manual is one place to start.
We don’t have a coding style guide for the project but the main thing is to ensure you use tabs rather than spaces to indent your code and try to keep the structure of the code you add as close a possible to what’s already in the library. This helps readability and makes the job of the repo owner who merges your change in a lot easier.
Mapstraction now has a build process which you should ensure passes before you send a pull request. There are several steps however the crucial one is that it performs a JSLint on the code to ensure certain bad JavaScript constructs haven’t crept in. The JSLint not only forces some consistency in formatting but also removes quite a lot of possible bugs before they can occur. Some source code editors like Aptana Studio have JSLint built in so it’s worth checking if yours does and turning it on for editing the Mapstraction source and probably the rest of your JavaScript code as it’s a good set of rules to stick to.
JavaScript developers may not be familiar with Apache Ant, which is required to build the project. If you can install Ant in your development environment, you can run the build (build.xml) to make sure your changes don’t break it. That will help ensure that your pull requests are accepted. Simply navigating your command line to the folder with the build.xml file in and running ant from there should work.
- Bing Maps AJAX Control, Version 6.3
- Bing Maps AJAX Control, Version 7.0
- Cloudmade
- Google v2
- Google v3
- MapQuest
- MultiMap
- OpenLayers v2.9.1
- Ovi Maps
-
-Yahoo v3.8- (Yahoo no longer offers, suggest Ovi instead.)