-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5f3faca
commit f5a20ef
Showing
5 changed files
with
71 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# Git Integration & Wix CLI <img align="left" src="https://user-images.githubusercontent.com/89579857/185785022-cab37bf5-26be-4f11-85f0-1fac63c07d3b.png"> | ||
|
||
This repo is part of Git Integration & Wix CLI, a set of tools that allows you to write, test, and publish code for your Wix site locally on your computer. | ||
|
||
Connect your site to GitHub, develop in your favorite IDE, test your code in real time, and publish your site from the command line. | ||
|
||
## Set up this repository in your IDE | ||
This repo is connected to a Wix site. That site tracks this repo's default branch. Any code committed and pushed to that branch from your local IDE appears on the site. | ||
|
||
Before getting started, make sure you have the following things installed: | ||
* [Git](https://git-scm.com/download) | ||
* [Node](https://nodejs.org/en/download/), version 14.8 or later. | ||
* [npm](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm) or [yarn](https://yarnpkg.com/getting-started/install) | ||
* An SSH key [added to your GitHub account](https://docs.github.com/en/authentication/connecting-to-github-with-ssh/adding-a-new-ssh-key-to-your-github-account). | ||
|
||
To set up your local environment and start coding locally, do the following: | ||
|
||
1. Open your terminal and navigate to where you want to store the repo. | ||
1. Clone the repo by running `git clone <your-repository-url>`. | ||
1. Navigate to the repo's directory by running `cd <directory-name>`. | ||
1. Install the repo's dependencies by running `npm install` or `yarn install`. | ||
1. Install the Wix CLI by running `npm install -g @wix/cli` or `yarn global add @wix/cli`. | ||
Once you've installed the CLI globally, you can use it with any Wix site's repo. | ||
|
||
For more information, see [Setting up Git Integration & Wix CLI](https://support.wix.com/en/article/velo-setting-up-git-integration-wix-cli-beta). | ||
|
||
## Write Velo code in your IDE | ||
Once your repo is set up, you can write code in it as you would in any other non-Wix project. The repo's file structure matches the [public](https://support.wix.com/en/article/velo-working-with-the-velo-sidebar#public), [backend](https://support.wix.com/en/article/velo-working-with-the-velo-sidebar#backend), and [page code](https://support.wix.com/en/article/velo-working-with-the-velo-sidebar#page-code) sections in Editor X. | ||
|
||
Learn more about [this repo's file structure](https://support.wix.com/en/article/velo-understanding-your-sites-github-repository-beta). | ||
|
||
## Test your code with the Local Editor | ||
The Local Editor allows you test changes made to your site in real time. The code in your local IDE is synced with the Local Editor, so you can test your changes before committing them to your repo. You can also change the site design in the Local Editor and sync it with your IDE. | ||
|
||
Start the Local Editor by navigating to this repo's directory in your terminal and running `wix dev`. | ||
|
||
For more information, see [Working with the Local Editor](https://support.wix.com/en/article/velo-working-with-the-local-editor-beta). | ||
|
||
## Preview and publish with the Wix CLI | ||
The Wix CLI is a tool that allows you to work with your site locally from your computer's terminal. You can use it to build a preview version of your site and publish it. You can also use the CLI to install [approved npm packages](https://support.wix.com/en/article/velo-working-with-npm-packages) to your site. | ||
|
||
Learn more about [working with the Wix CLI](https://support.wix.com/en/article/velo-working-with-the-wix-cli-beta). | ||
|
||
## Invite contributors to work with you | ||
Git Integration & Wix CLI extends Editor X's [concurrent editing](https://support.wix.com/en/article/editor-x-about-concurrent-editing) capabilities. Invite other developers as collaborators on your [site](https://support.wix.com/en/article/inviting-people-to-contribute-to-your-site) and your [GitHub repo](https://docs.github.com/en/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-access-to-your-personal-repositories/inviting-collaborators-to-a-personal-repository). Multiple developers can work on a site's code at once. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"extends": ["plugin:@wix/cli/recommended"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# dependencies | ||
node_modules/ | ||
.vscode/ | ||
.idea/ | ||
.wix/ | ||
jsconfig.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"devDependencies": { | ||
"@wix/cli": "^1.0.0", | ||
"@wix/eslint-plugin-cli": "^1.0.0", | ||
"eslint": "^8.25.0", | ||
"react": "16.14.0" | ||
}, | ||
"scripts": { | ||
"postinstall": "wix sync-types", | ||
"dev": "wix dev", | ||
"lint": "eslint ." | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"siteId": "7a96d103-c134-4918-84de-56b2c46f5be5", | ||
"uiVersion": "458" | ||
} |