1.0.4 • Published 10 years ago

atma-loader-yml v1.0.4

Weekly downloads
-
License
MIT
Repository
-
Last release
10 years ago

Yaml Parser (Atma Plugin)

Build Status

The Plugin extends:

How to use
Embed into the Project
  • atma plugin install atma-loader-yml
    	This adds `atma-loader-less` npm dependency and the `package.json` would look like:
    	```json
    	{
    		"dependency": {
    			"atma-loader-yml"
    		},
    		"atma": {
    			"plugins": [
    				"atma-loader-yml"
    			],
    			"settings": {
    				"atma-loader-yml": {
    					"extension": "yml"
    				}
    			}
    		}
    	}
    	```
  • That's all. Now, you are ready to use yml instead of json in your project
Quick Try
  • install atma: $ npm install atma -g required once for plugin installation sugar
  • install plugin: $ atma plugin install atma-loader-yml
  • add test.html to the directory

    <!DOCTYPE html>
    <script src='http://cdn.jsdelivr.net/g/jquery'></script>
    <script>
    	$.getJSON('/test.yml').then(function(json) {
    		console.log(json);
    	})
    </script>
  • add test.yml

    name: Foo
  • start the server: $ atma server
  • open the browser: http://localhost:5777/test.html

(c) MIT License - Atma.js Project