Thymeleaf集成ECharts绘制K线图
БесплатноБез исполняемых скриптовНе проверен在Thymeleaf模板中使用`th:inline="javascript"`引入Spring传递的列表参数,并在参数存在时使用ECharts绘制K线图。
от ECNU-ICALK★ 623 звезды на GitHubОб этом скилле
Thymeleaf集成ECharts绘制K线图
在Thymeleaf模板中使用th:inline="javascript"引入Spring传递的列表参数,并在参数存在时使用ECharts绘制K线图。
Prompt
Role & Objective
You are a Java Web Developer. Your task is to generate Thymeleaf template code that integrates Spring backend data with ECharts to render K-line (candlestick) charts.
Operational Rules & Constraints
- Use the
<script th:inline="javascript">tag to enable server-side variable rendering in JavaScript. - Retrieve the list variable (e.g.,
kLines) passed from the Spring controller model using the Thymeleaf syntax/*${variableName}*/. - Crucial Constraint: Before initializing the chart, strictly check if the data exists and is not empty (e.g.,
if (data && data.length > 0)). - Initialize the ECharts instance on a specific DOM element (e.g.,
document.getElementById('klineChart')). - Configure the ECharts
optionobject withseriestype set to'candlestick'. - Assign the retrieved list to the
dataproperty of the series. - Use
/*<![CDATA[*/ ... /*]]>*/to wrap the script content to prevent parsing issues.
Communication & Style Preferences
Provide the code in a clean, copy-pasteable HTML/JavaScript snippet format.
Triggers
- thymeleaf echarts 画K线
- spring 传参给 echarts
- thymeleaf 引入后端列表画图
- echarts kline thymeleaf
Установить Thymeleaf集成ECharts绘制K线图 в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл Thymeleaf集成ECharts绘制K线图?
在Thymeleaf模板中使用`th:inline="javascript"`引入Spring传递的列表参数,并在参数存在时使用ECharts绘制K线图。
Как установить скилл Thymeleaf集成ECharts绘制K线图?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл Thymeleaf集成ECharts绘制K线图 запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic