Variable: web-mode-links

web-mode-links is a variable defined in web-mode.el.

Value

(("\\.\\(png\\|jpe?g\\|gif\\|webp\\)$" "<img src=\"%s\" alt=\"\" />"
  nil 4)
 ("\\.svg$" "<object data=\"%s\" type=\"image/svg+xml\"></object>" nil
  0)
 ("\\.js$" "<script type=\"text/javascript\" src=\"%s\"></script>" t 0)
 ("\\.css$"
  "<link rel=\"stylesheet\" type=\"text/css\" href=\"%s\" />" t 0)
 ("\\.html?$" "<a href=\"%s\"></a>" nil 4))

Documentation

List of elements and extensions for web-mode-file-link. It consists of a string that contains the regular expression that matches the appropriate files, a format string with element that contains the link (%s should be put where the path goes,) a bool that tells if the element belongs in the <head> element, and number of characters to move back if needed (or 0 if point shouldn't be moved back.)

Source Code

;; Defined in /nix/store/2qgnz1rp30nzfz6w0apx4kdm14if1bbs-emacs-packages-deps/share/emacs/site-lisp/elpa/web-mode-20260831.219/web-mode.el
(defvar web-mode-links
  '(("\\.\\(png\\|jpe?g\\|gif\\|webp\\)$" "<img src=\"%s\" alt=\"\" />" nil 4)
    ("\\.svg$" "<object data=\"%s\" type=\"image/svg+xml\"></object>" nil 0)
    ("\\.js$" "<script type=\"text/javascript\" src=\"%s\"></script>" t 0)
    ("\\.css$" "<link rel=\"stylesheet\" type=\"text/css\" href=\"%s\" />" t 0)
    ("\\.html?$" "<a href=\"%s\"></a>" nil 4))
  "List of elements and extensions for `web-mode-file-link'. It
consists of a string that contains the regular expression that
matches the appropriate files, a format string with element that
contains the link (%s should be put where the path goes,) a bool
that tells if the element belongs in the <head> element, and
number of characters to move back if needed (or 0 if point
shouldn't be moved back.)")