branch: elpa/web-mode commit 38013bcec72b93e29ffc3ce7fc7c20e233ea5c01 Author: fxbois <fxb...@gmail.com> Commit: fxbois <fxb...@gmail.com>
React.Fragment fix #1327 --- issues/1327.jsx | 9 +++++++++ web-mode.el | 8 ++++---- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/issues/1327.jsx b/issues/1327.jsx new file mode 100644 index 00000000000..56ee82f7bd4 --- /dev/null +++ b/issues/1327.jsx @@ -0,0 +1,9 @@ +const Hello = (props) => { + return ( + <React.Fragment> + <p> + Hi, {props.name} + </p> + </React.Fragment> + ); +}; diff --git a/web-mode.el b/web-mode.el index a4c1fb21d85..5b640012f6e 100644 --- a/web-mode.el +++ b/web-mode.el @@ -1,8 +1,8 @@ ;;; web-mode.el --- major mode for editing web templates -*- coding: utf-8; lexical-binding: t; -*- -;; Copyright 2011-2024 François-Xavier Bois +;; Copyright 2011-2025 François-Xavier Bois -;; Version: 17.3.21 +;; Version: 17.3.22 ;; Author: François-Xavier Bois ;; Maintainer: François-Xavier Bois <fxb...@gmail.com> ;; Package-Requires: ((emacs "23.1")) @@ -23,7 +23,7 @@ ;;---- CONSTS ------------------------------------------------------------------ -(defconst web-mode-version "17.3.21" +(defconst web-mode-version "17.3.22" "Web Mode version.") ;;---- GROUPS ------------------------------------------------------------------ @@ -6336,7 +6336,7 @@ Also return non-nil if it is the command `self-insert-command' is remapped to." (defun web-mode-jsx-skip (reg-end) ;; #1299 (let ((continue t) (pos nil) (i 0) (tag nil) (regexp nil) (regexp0 nil) (regexp1 nil) (counter 0) (ret nil) (match nil) (inside t)) - (looking-at "<\\([[:alpha:]][[:alnum:]:-]*\\)") + (looking-at "<\\([[:alpha:]][[:alnum:].:-]*\\)") ;; #1327 (setq tag (match-string-no-properties 1)) (if (null tag) (progn