From f3604ebbf22e8fc8e6fef4f807ecf3476e142e4a Mon Sep 17 00:00:00 2001
From: Zhen Li <45376537+li3zhen1@users.noreply.github.com>
Date: Wed, 17 Jan 2024 14:47:59 -0500
Subject: [PATCH] Update README.md
---
README.md | 46 ++++++++++++++++++++++++++++++++++++++--------
1 file changed, 38 insertions(+), 8 deletions(-)
diff --git a/README.md b/README.md
index 3fd2290..d105d3f 100644
--- a/README.md
+++ b/README.md
@@ -79,11 +79,47 @@ https://github.com/li3zhen1/Grape/assets/45376537/5b76fddc-dd5c-4d35-bced-29c012
Source code: [Lattice.swift](https://github.com/li3zhen1/Grape/blob/main/Examples/ForceDirectedGraphExample/ForceDirectedGraphExample/Lattice.swift)
+
+
+Here is another example rendering a ring with 60 vertices, with out-of-the-box dragging support.
+
+
+
+https://github.com/li3zhen1/Grape/assets/45376537/73213e7f-73ee-44f3-9b3e-7e58355045d2
+
+
+
+## Installation
+
+To use Grape in an Xcode project by adding it to your project as a package:
+
+```
+https://github.com/li3zhen1/Grape
+```
+
+To use Grape in a [SwiftPM](https://swift.org/package-manager/) project, add this to your `Package.swift`:
+
+``` swift
+dependencies: [
+ .package(url: "https://github.com/li3zhen1/Grape", from: "0.6.1")
+]
+```
+
+Add to products, and then adding the product to any target that needs access to the library.
+
+```swift
+.product(name: "Grape", package: "Grape"),
+```
+
+
+
+
+
## Get started
Grape ships 2 modules:
@@ -95,8 +131,8 @@ Grape ships 2 modules:
### The `Grape` module
-> [!TIP]
-> For detailed usage, please refer to [documentation](https://li3zhen1.github.io/Grape/Grape/documentation/grape) to get started.
+
+For detailed usage, please refer to [documentation](https://li3zhen1.github.io/Grape/Grape/documentation/grape). A quick example here:
```swift
import Grape
@@ -125,12 +161,6 @@ struct MyGraph: View {
}
```
-Below is another [example](https://github.com/li3zhen1/Grape/blob/main/Examples/ForceDirectedGraphExample/ForceDirectedGraphExample/MyRing.swift) rendering a ring with 60 vertices, with out-of-the-box dragging support:
-
-https://github.com/li3zhen1/Grape/assets/45376537/73213e7f-73ee-44f3-9b3e-7e58355045d2
-
-
-