ForgeComposants
fr

Composants

j-JSONTree

jComponent 20 · jcomponent@20 component Exemple chargé avec jComponent 20

j-JSONTree crée une arborescence à partir de données json.


Configuration :

  • click {String} un lien vers le function(selected_path, component)

Utilisez-le avec <ui-component name="jsontree">. Lorsque le composant n'est pas encore chargé, jComponent le télécharge lors de la première utilisation depuis l'adresse dans DEF.fallback (le CDN Componentator par défaut). Auteur : Martin Smola. Source : le référentiel de composants Componentator, licence MIT.

example.html
<ui-component name="jsontree" path="json" config="click:jsontree_click">Sample JSON data</ui-component>
<script>

	setTimeout(function() {
		SET('json', '{"datecreated":"2018-06-18T22:27:00.000Z","name":"j-JSONTree","color":"transparent","version":1,"responsive":true,"picture":"picture.png","dependencies":"","author":"Martin Smola","email":"smola.martin@gmail.com","license":"MIT"}');
	}, 2000);

	function jsontree_click(path) {
		console.log('Path:', path);
	};
</script>