Bugs fixed, what's new, and more! :)
- Corrects incorrect diagnostics for some operators (#97)
- Corrects an issue where "and" would cause incorrect diagnostic reports (#95)
- Corrects an issue when formatting escape sequences in nested strings (#90)
- Improves type checking of event arguments to prevent console errors (#88)
- Adds support for the
select
modifier - Adds support for
flatten
'sdepth
parameter - Adds support for the
keys
modifier - Adds support for the
values
modifier - Adds support for the
attribute
modifier
- Corrects an issue when using
{{# format-ignore-start #}}
(#87)
- Corrects an issue when formatting interpolated content in conditions (#85)
- Corrects an issue causing required partial parameter errors from appearing on closing tags (#84)
- Provides partial parameter descriptions in suggestions.
- Corrects a few formatting bugs (#80)
- Corrects an issue where extra whitespace is added around
->
method invocation syntax
- Corrects an issue with string array indexes duplicating leading variable names when formatting (#79)
- Improves formatting of
<script>
and<style>
tags when multiple appear in a document, and at least one contains Antlers tag pairs - Improves highlighting of HTML tags inside HTML comments (#78)
- Renames internal
template_contents
variable totemplate_content
- Improves error reporting surrounding array syntax
- Adds language server support for experimental escaped Antlers parameter syntax
- Adds support for the
classes
modifier - Adds support for the
svg
tag'ssanitize
parameter - Adds support for the
svg
tag'sallow_attrs
parameter - Adds support for the
svg
tag'sallow_tags
parameter - Adds support for the
is_svg
augmented assets variable - Improves support for partial linking when omitting the "partials/" directory prefix
- Corrects an issue where the formatter may duplicate content within
<script>
tags (#76)
- Improves directory scanning logic (#74)
- Improves error reporting with arrays as modifier values
- Improves modifier type diagnostics reporting
- Refactors how Antlers comment styles are applied (watches for file changes to apply only on
.antlers.html
and.antlers.xml
)
- Removes block comments from the Antlers configuration file, relying entirely on the setting when the extension is activated
- Improves formatting of comments when they begin a line and are followed by a literal node (#71)
- Adds completion support for custom Tags and modifiers,
- Improves general formatting,
- Improves modifier completions and parameter suggestions, particularly with method-style syntax,
- Adds initial support for select Statamic Marketplace addon tags and modifiers,
aerni/social-links
aerni/advanced-seo
aerni/livewire-forms
anakadote/statamic-recaptcha
aryehraber/statamic-captcha
cnj/seotamic
ddm-studio/cookie-byte
doublethreedigital/simple-commerce
jonassiewertsen/statamic-livewire
kolaente/statamic-snippet
octoper/statamic-inline-assets
parfaitementweb/statamic-fast-seo
statamic/seo-pro
stillat/antlers-layouts
visuellverstehen/statamic-classify
withcandour/aardvark-seo
- Adds support custom Collection Tag filter autocomplete
- Improves static analysis of Query Builder modifier detection
- Improves formatting of tags using strict-tag syntax
- Corrects an issue when formatting ignored regions containing tag pairs
- Improves formatting of interpolated variables
- Adds the ability to disable formatting template sections
To disable formatting, we can use the special {{# format-ignore-start #}}
and {{# format-ignore-end #}}
Antlers comments:
<div>
<div>
{{# format-ignore-start #}}
<div class="class1 class2">
This section
will not be formatted.
</div>
{{# format-ignore-end #}}
</div>
</div>
The special formatting comments must appear on separate lines by themselves.
- Improves formatting of strings inside
unless
Tags
- Improves server stability when analyzing dynamic classes
- Improves tag parameter suggestions
- Corrects an issue that could lead to incomplete tags adding extra newlines after formatting
- Corrects an issue with formatting Antlers tags within HTML attributes
- Improves error reporting of tags containing
::
to align with latest Antlers version - Improves error reporting of Antlers tags starting with array literals
- Improves partial tag completions inside nested scopes
- Improves formatting of dynamic HTML elements
- Adds support for the
user:password_form
tag - Adds support for the
user:profile_form
tag
- Improves descriptions for the
first
andlast
modifiers - Improves the consistency of modifier and modifier parameter descriptions
- Corrects a handful of typos in modifier descriptions
- Improves the internal support for
assets
variables - Improves the consistency of tag and tag parameter descriptions
- Corrects a handful of tag/parameter description typos
- Improves internal management of collections without any user blueprint customizations
- Adds collections without any user blueprint modifications to suggestions
- Adds field injections to completion results for collections without any user blueprint modifications
- Adds blueprint overview and automated documentation generation (beta)
- Improves parser support for Antlers
list
keyword - Improves internal support for
assets
fieldtypes - Adds internal support for detecting Query Builder augmented fields
- Internally resolves blueprint and field-type field references where there has not been enough context to do so historically
- Provides linting feedback when tag parameter values are not surrounded in single or double quotes
- Adds the ability to disable all diagnostics warnings using the
antlersLanguageServer.diagnostics.reportDiagnostics
configuration option - Adds warnings when using the
join
orjoinplode
modifiers directly onselect
fieldtypes - The formatters no longer format
<script>
tags when they contain Antlers tag pairs - Adds warnings when using modifiers directly on fields that augment to query builders
- Antlers Toolbox no longer requires editing files/restarting Visual Studio Code in order for error reporting to update after changing the current language version
- Improvements to internal modifier suggestion management and parsing
- Adds support for the
bool_string
modifier - Adds common date/time format variables to the
format
modifier's hover tooltip - Adds support for the
when
andunless
partial tag parameters - Improves tag-specific contextual completion suggestions
- Improves line wrapping when formatting method-style modifiers
- Adds support for the
key_by
modifier - Adds support for the
mark
modifier - Adds support for the
regex_mark
modifier - Adds support for the
page_name
Collection parameter - Adds support for the
cookie
tags - Adds support for the
glide:data_url
tag
- Improves parsing of tag names containing "or" in the method part (#49)
- Improves indentation when formatting Antlers structures inside embedded documents
- Adds
user
completion item to thecache
tag'sscope
parameter - Adds
collection_term_workaround
completion item to thelocales
tag - Adds
blueprint
entry variable to scope and completion items - Adds support for the
antlers
modifier - Adds support for the
bard_text
modifier - Adds support for the
bard_html
modifier - Adds support for the
bard_items
modifier - Adds support for the
user_roles
tag - Adds support for the
user_groups
tag
- Fixes a bug that would split up tag names if they contained characters that look like operators
- Improves the preservation of line breaks when formatting
- Improves formatting of expanded inline
switch
groups - Preserves space on nested
switch
orlist
operators
- Adds additional YAML parsing checks to prevent crashing the language server
- Improves parsing and error reporting of array access variables
- Warning
ANTLER_521
will now be emitted for deprecated modifiers - Deprecated modifiers will no longer appear in suggestions
- Warning
ANTLER_520
will now be emitted when dynamic CSS class names are detected
- Corrects an issue when Front Matter documents
- Makes the removal of new lines after formatting less aggressive
- Disables the request input diagnostics handler temporarily
- Corrects an issue where
}}
could be duplicated following a comment and there are no other Antlers nodes in the document
- Corrects an issue where some content may be deleted after a comment and there is no other Antlers in the document
Note: This version removes the
Antlers: Use Prettier First
configuration option. This option has been removed in favor of an Antlers Prettier Plugin. Impacted users should consider installing and configuring this plugin: https://www.npmjs.com/package/prettier-plugin-antlers
- Introduces a new underlying formatting engine
- Removes the
Antlers: Use Prettier First
configuration option - Adds support for the
nocache
tag - Emits warnings when request variables (
get
orpost
) do not have thesanitize
modifier applied to their output
- Improves parsing of parameters that begin with numbers
- Adds support for the
{{ vite }}
tag - Improves linting of tag parameters that utilize dynamic binding
- Adds "Refactor to partial..." code action
- Adds convert condition to ternary or gatekeeper operator refactors
- User created Antlers variables will now appear within completion suggestions
- Tag pairs within interpolations will now report their errors properly
- Adds support for the
[ANTLR_131] Unpaired closing tag
error - Improves error message reporting (reduces multiple warning variants, removes some duplicates, etc.)
- Fixes inconsistent final newline formatting
- Adds support for detecting recursive partials
- Renames
mount
tag tomount_url
tag - Adds support for the
to_bool
modifier - Improves parsing of Front Matter variables within partials
- Validates required partial parameters when marked required using
@param*
IDE hints - Fixes a handful of bugs related to IDE hints and partials
- Fixes partial parameter suggestions not appearing
- Adds support for the
mount
tag
- Improves formatting of Antlers inside conditions containing
<script>
tags
- Improves formatting of Antlers inside
<script>
tags
- Updates types supported by the
first
andlast
modifier to improve error reporting
- Adds
.antlers.php
and.antlers.xml
extensions - Adds
AVIF
option to Glide suggestions
- Improves behavior of
noparse
regions - Improves formatting of
switch
operators - Removes Antlers before formatting with Prettier (if enabled)
- Improves error reporting when using modifiers within the
groupby
operator - Adds
stack
andpush
to the syntax highlighting tag list
- Corrects an issue where the formatter would not emit
:
or.
when used as variable components #24
- Renames the
ANTLER_507
linter error code toANTLR_507
for consistency
- Adds hyphenated variable support to the Antlers formatter
- Prevents comments from being parsed as Antlers #23
- Dramatically improves accuracy of the out-of-box syntax highlighting experience
- Antlers is now highlighted within HTML attributes
- Modifier value colors now longer "flow" into the next token type
- All default Statamic variables are no longer given any special preference over user variables for consistency
- The default style for tag names has been subtly adjusted, to make them more distinct from method names
- Adds support for Front Matter YAML syntax highlighting
- Adds support for inline PHP syntax highlighting
- The Antlers Outline panel was completely rewritten to provide better accuracy, and provide a more thorough overview of your Antlers template
- Antlers code folding engine has been greatly improved
- Pagination parameter analysis will now apply to numeric values in addition to boolean values
- Document diagnostics analysis for debug tags and modifiers are now more reactive
- Improved detection of partial document links
- Improves partial document link generation such that partial tag parameters are no longer links
- Improves the Antlers formatter
- Removed the extensibility API until the new parser is fully implemented
- Removed the bundled PHP analyzer to simplify the extension development and management
- The TextMate grammar was rewritten from the ground up, to provide better interoperability with tools like TorchLight
- The Semantic Tokens service was also rewritten, and simplified. The Semantic Tokens service now handles the following cases (instead of most things like before):
- Resolving modifier names in more complicated scenarios
- Resolving user-provided tag names
- Resolving numeric values
- The Semantic Tokens service was also rewritten, and simplified. The Semantic Tokens service now handles the following cases (instead of most things like before):
- A new backend parser and reflection API
- The backend services are now capable of handling more complex fault scenarios such as incomplete Antlers tags, incorrectly paired tags, etc. while continuing to provide document analysis
- The project's
publish:grammar
NPM script has been removed in favor of editing theantlers.json
syntax file directly
- Prevents the formatter from adding
undefined
to templates when conditional line leading whitespace is unknown (#15)
- Improves the formatting behavior of
unless
conditionals (#14)
- Adds support for the
all
andself
locale tag parameters - Improves default variable support for the
locale
tag
- Adds support for the
array
when using theforeach
anditerate
tags
- Adds a new
antlersOverrideHtmlComments
configuration option that can be used to always use Antlers comments in HTML documents - Adds support for the
split
array modifier - Adds support for the
format_translated
date modifier - Adds support for the
add_slashes
string modifier - Adds additional scope variables for the
nav
tag - Adds support for
exists
andif_exists
methods on thepartial
tag - Improves completions for manifested array variables when using parameter-style modifiers
- Improves internal scope resolution
- Improves validation warnings with the
glide
tag
- Makes improvements to partial suggestions
- Background work to support an eventual Antlers Debugger
- Developers can now use VS Code's document links to navigate to detected partial files
- Developers can now see an overview/outline of their Antlers document within the Outline panel
- Removes
name
from the list ofstatamic-tag-native-variable
to improve out-of-box syntax highlighting consistency #11
- The extension will no longer display warnings for unknown parameters (based on user feedback)
- Adds support for the field set prefixes when importing field-sets in auto-completion
- Adds support for the
installed
tag, with composer package autocompletions - Automatically detects variable names within partials and adds them to the tag's parameter auto complete list.