sainty.io

Sanity.ioのCLIツールをセットアップする方法

Headless, Composable系のCMS「sanity.io」のCLIツールをセットアップしてみました。 npxでCLIを起動・ログインする Sanityアカウントと連携するため、sanity loginを実行 […]

広告ここから
広告ここまで

Headless, Composable系のCMS「sanity.io」のCLIツールをセットアップしてみました。

https://www.sanity.io/

npxでCLIを起動・ログインする

Sanityアカウントと連携するため、sanity loginを実行しましょう。

% npx sanity login
? Login type (Use arrow keys)
❯ Google 
  GitHub 
  E-mail / password 

ブラウザが立ち上がり、ログイン画面が開きます。

完了画面が表示されたら成功です。

利用できるコマンドなど

sanify helpでコマンドを調べることができます。

usage: sanity [--default] [-v|--version] [-d|--debug] [-h|--help] <command> [<args>]

Commands:
   build      Builds the current Sanity configuration to a static bundle
   codemod    Runs a code modification script
   cors       Interact with CORS-entries for your project
   dataset    Interact with datasets in your project
   debug      Gathers information on Sanity environment
   deploy     Deploys a statically built Sanity studio
   dev        Starts a development server for the Sanity Studio
   docs       Opens the Sanity documentation
   documents  Interact with documents in your project
   exec       Runs a script in Sanity context
   graphql    Interact with GraphQL APIs
   help       Displays help information about Sanity
   hook       Interact with hooks in your project
   init       Initialize a new Sanity studio project
   install    Installs dependencies of the current project
   login      Authenticates against the Sanity.io API
   logout     Logs out of the Sanity.io session
   manage     Opens the Sanity project management UI
   preview    Starts a local web server for previewing production build
   projects   Interact with projects connected to your logged in user
   start      Alias of `sanity preview`
   undeploy   Removes the deployed studio from <hostname>.sanity.studio
   users      Manage users of your project
   versions   Shows the installed versions of Sanity CLI and core components

ブックマークや限定記事(予定)など

WP Kyotoサポーター募集中

WordPressやフロントエンドアプリのホスティング、Algolia・AWSなどのサービス利用料を支援する「WP Kyotoサポーター」を募集しています。
月額または年額の有料プランを契約すると、ブックマーク機能などのサポーター限定機能がご利用いただけます。

14日間のトライアルも用意しておりますので、「このサイトよく見るな」という方はぜひご検討ください。

広告ここから
広告ここまで

Related Category posts