Skip to content

Commit 436c390

Browse files
committed
docs: remove LWR-specific development instructions
- Removed entire 'LWR Sites Development Environment' section - Removed references to yarn link-lwr commands - Removed LWR debugging instructions - Simplified debugging section to focus on plugin debugging only - Updated to be more generic and applicable to all commands
1 parent af473ed commit 436c390

File tree

1 file changed

+7
-44
lines changed

1 file changed

+7
-44
lines changed

README.md

Lines changed: 7 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -69,59 +69,22 @@ sf plugins link .
6969
sf plugins
7070
```
7171

72-
## LWR Sites Development Environment
72+
## Debugging
7373

74-
Follow these instructions if you want to setup a dev environment for the `sf lightning dev site` command.
75-
76-
## Setup
77-
78-
1. [Enable Local Development](https://developer.salesforce.com/docs/platform/lwc/guide/get-started-test-components.html#enable-local-dev)
79-
80-
2. Deploy some source files to your org from your SFDX project
81-
82-
```bash
83-
sf org login web --alias dev --instance-url ${orgfarmUrl}
84-
85-
```
86-
87-
3. Add those source files to an LWR site in the Experience Builder and Publish the site (basePath: '/')
88-
89-
4. Follow the [Build the plugin locally](#build) instructions
90-
91-
5. [optional] Linking / Debugging LWR Source
74+
To debug the plugin, you can use the Node.js debugger:
9275

9376
```bash
94-
# build and link lwr source
95-
cd lwr
96-
yarn && yarn link-lwr
97-
98-
# build and link plugin-lightning-dev source
99-
cd plugin-lightning-dev
100-
yarn && yarn build
101-
yarn link-lwr
102-
103-
# SFDX Project
104-
cd sfdx-project
105-
106-
# Login to your org
107-
sf org login web --alias dev --instance-url https://login.test1.pc-rnd.salesforce.com/ (orgfarm needs instance url)
108-
109-
# run/debug the sf cli command (attach to the CLI from the LWR repo in VS Code)
110-
NODE_OPTIONS="--inspect-brk" sf lightning dev site --target-org dev
77+
# Run with debugger attached
78+
NODE_OPTIONS="--inspect-brk" sf lightning dev site --target-org <your-org>
11179
```
11280

113-
Now you can Remote Attach to the CLI from the vscode debugger:
114-
115-
- Use the "Attach" launch configuration
116-
- Run launch config from LWR repo if you want to debug LWR source
117-
- Run launch config from plugin-lightning-dev source if you want to debug the SFDX plugin source specifically
81+
Now you can attach to the process from your IDE's debugger using the "Attach" launch configuration.
11882

119-
If this doesn't work for whatever reason, you can always alias the build output directly like so:
83+
Alternatively, you can alias the build output directly:
12084

12185
```bash
12286
alias sfdev="/{pathToGitDir}/plugin-lightning-dev/bin/run.js"
123-
# SFDX Project
124-
NODE_OPTIONS="--inspect-brk" sfdev lightning dev site --target-org dev
87+
NODE_OPTIONS="--inspect-brk" sfdev lightning dev site --target-org <your-org>
12588
```
12689

12790
6. Make changes to your c-namespace components and you should see the browser refresh with those changes!

0 commit comments

Comments
 (0)