From 51246d82f74162c4779de01409121d6e396836a5 Mon Sep 17 00:00:00 2001 From: FĂ©lix Sanz Date: Sat, 11 Nov 2023 19:40:32 +0100 Subject: feat: adding astro files support via JSX language syntax (#337) * feat: adding astro files support via JSX language syntax * Update manifest.json * Update plugins/language_jsx.lua Co-authored-by: Guldoman * Update plugins/language_jsx.lua Co-authored-by: Guldoman * Apply suggestions from code review Co-authored-by: Guldoman * Update language_jsx.lua --------- Co-authored-by: Guldoman --- plugins/language_jsx.lua | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'plugins/language_jsx.lua') diff --git a/plugins/language_jsx.lua b/plugins/language_jsx.lua index 04e846b..941e786 100644 --- a/plugins/language_jsx.lua +++ b/plugins/language_jsx.lua @@ -4,10 +4,11 @@ local syntax = require "core.syntax" syntax.add { name = "JSX", - files = { "%.jsx$" }, + files = { "%.jsx$", "%.astro$" }, comment = "//", + block_comment = { "/*", "*/" }, patterns = { - { pattern = "//.-\n", type = "comment" }, + { pattern = "//.*", type = "comment" }, { pattern = { "/%*", "%*/" }, type = "comment" }, { pattern = { '"', '"', '\\' }, type = "string" }, { pattern = { "'", "'", '\\' }, type = "string" }, -- cgit v1.2.3