Token导航 LogoToken导航TokenDH.com
研究检索敏感数据github未标认证来源可访问clear审计通过

shopify-remix-templateShopify remix template 搜索

Agent Skill

shopify-remix-template 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

451

周安装

19

GitHub Stars

公开资料未说明

下载量

158
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

3

许可证

MIT

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:shopify-remix-template(Shopify remix template 搜索)
来源仓库:https://github.com/toilahuongg/google-antigravity-kit
仓库路径:skills/shopify-remix-template
安装命令:
npx skills add https://github.com/toilahuongg/google-antigravity-kit --skill shopify-remix-template
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/toilahuongg/google-antigravity-kit --skill shopify-remix-template

简介

用于检索 Shopify Remix 应用模板的结构与集成方法。

  • 适合快速启动全栈电商项目并理解路由、认证与主题绑定机制。
  • 通过 npx 命令安装,兼容 Codex、Claude 等 AI 代码宿主环境。
  • 建议在使用前核对 Remix 版本与 Shopify CLI 的兼容性。
  • shopify-remix-template 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

SKILL.md

Shopify Remix Template Guide

This skill provides a guide for building Shopify apps using the official Shopify Remix App Template. This template is the recommended starting point for most new Shopify embedded apps (though React Router is the future direction, Remix is still widely used and supported).

🚀 Getting Started

To create a new app using the Remix template, run:

git clone https://github.com/Shopify/shopify-app-template-remix.git

📂 Project Structure

A typical Remix app structure:

  • app/

- routes/: File-system based routing. - app._index.tsx: The main dashboard page. - app.tsx: The root layout for the authenticated app. - webhooks.tsx: Webhook handler. - shopify.server.ts: Critical. Initializes the Shopify API client, authentication, and session storage (Redis). - db.server.ts: Database connection (Mongoose). - models/: Mongoose models (e.g., Session.ts, Shop.ts). - root.tsx: The root component for the entire application.

  • shopify.app.toml: Main app configuration file.

🔐 Authentication & Sessions

The template uses @shopify/shopify-app-remix to handle authentication automatically.

shopify.server.ts

This file exports an authenticate object used in loaders and actions. It is configured to use Redis for session storage.

import { shopifyApp } from "@shopify/shopify-app-remix/server";
import { RedisSessionStorage } from "@shopify/shopify-app-session-storage-redis";

const sessionDb = new RedisSessionStorage(
  new URL(process.env.REDIS_URL!)
);

const shopify = shopifyApp({
  apiKey: process.env.SHOPIFY_API_KEY,
  apiSecretKey: process.env.SHOPIFY_API_SECRET,
  appUrl: process.env.SHOPIFY_APP_URL,
  scopes: process.env.SCOPES?.split(","),
  apiVersion: "2025-10",
  sessionStorage: sessionDb,
  isEmbeddedApp: true,
});

export const authenticate = shopify.authenticate;
export const apiVersion = "2025-10";
export const addDocumentResponseHeaders = shopify.addDocumentResponseHeaders;

Usage in Loaders (Data Fetching)

Protect routes and get the session context:

import { json } from "@remix-run/node";
import { authenticate } from "../shopify.server";

export const loader = async ({ request }) => {
  const { admin, session } = await authenticate.admin(request);

  // Use admin API
  const response = await admin.graphql(`...`);

  return json({ data: response });
};

📡 Webhooks

Webhooks are handled in app/routes/webhooks.tsx (or individual route files). The template automatically registers webhooks defined in shopify.server.ts.

To add a webhook:

  1. Add configuration in shopify.server.ts.
  2. Handle the topic in the action of app/routes/webhooks.tsx.

🗄️ Database (Mongoose/MongoDB)

Use Mongoose for persistent data storage (Shops, Settings, etc.).

app/db.server.ts

Singleton connection to MongoDB.

import mongoose from "mongoose";

let isConnected = false;

export const connectDb = async () => {
  if (isConnected) return;

  try {
    await mongoose.connect(process.env.MONGODB_URI!);
    isConnected = true;
    console.log("🚀 Connected to MongoDB");
  } catch (error) {
    console.error("❌ MongoDB connection error:", error);
  }
};

app/models/Shop.ts (Example)

import mongoose from "mongoose";

const ShopSchema = new mongoose.Schema({
  shop: { type: String, required: true, unique: true },
  accessToken: { type: String, required: true },
  isInstalled: { type: Boolean, default: true },
});

export const Shop = mongoose.models.Shop || mongoose.model("Shop", ShopSchema);

Usage in Loaders

Connect to the DB before using models.

import { connectDb } from "../db.server";
import { Shop } from "../models/Shop";

export const loader = async ({ request }) => {
  await connectDb();
  // ...
  const shopData = await Shop.findOne({ shop: session.shop });
  // ...
};

🎨 UI & Design (Polaris)

The template comes pre-configured with Polaris, Shopify's design system.

  • Wrap your pages in <Page> components.
  • Use <Layout>, <Card>, and other Polaris components for a native feel.
  • App Bridge is initialized automatically in app.tsx.

🛠️ Common Tasks

1. Adding a Navigation Item

Update app/routes/app.tsx:

<ui-nav-menu>
  <Link to="/app">Home</Link>
  <Link to="/app/settings">Settings</Link>
</ui-nav-menu>

2. Fetching Data from Shopify

Use the admin object from authenticate.admin(request) to make GraphQL calls.

3. Deploying

  • Hosting: Remix apps can be hosted on Vercel, Fly.io, Heroku, or Cloudflare.
  • Database: Ensure you have a persistent database (e.g., Postgres) for production.
  • Environment Variables: Set SHOPIFY_API_KEY, SHOPIFY_API_SECRET, SCOPES, SHOPIFY_APP_URL.

📚 References

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

04

需要参考平台分布和安装热度时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Claude Code

29.58%
按下载量换算47

OpenCode

20.45%
按下载量换算32

Antigravity

18.28%
按下载量换算29

github-copilot

11.7%
按下载量换算18

windsurf

7.03%
按下载量换算11

Codex

3.59%
按下载量换算6

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。

来源信息

继续浏览同类 Skills