Skip to content
This repository has been archived by the owner on Jul 5, 2022. It is now read-only.

Show node type name rather than showing an icon? #23

Answered by Hubro
Hubro asked this question in Q&A
Discussion options

You must be logged in to vote

Never mind! Somehow, after asking this question I immediately figured it out. Turns out it was trivial to achieve with a transformation function.

	["yang"] = function(capture_name, capture_text)
		if capture_name == "container-name" then
			return "container "..capture_text
		elseif capture_name == "grouping-name" then
			return "grouping "..capture_text
		elseif capture_name == "list-name" then
			return "list "..capture_text
		elseif capture_name == "leaf-name" then
			return "leaf "..capture_text

		-- ...

		else
			return capture_text
		end
	end

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by Hubro
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant