Ross Gerbasi
03/03/2022, 5:52 PMroute.ts
to get SST to rebuild the function in memory. However if route.ts
depends on other files and they are updated an esbuild transpile is not triggered.
I keep finding myself in situations where I am making changes and not seeing results, and realize I forgot I need to go back and save any route's that depend on that file to get it to re-build in dev mode.
Am I totally missing something to get this to work better?thdxr
03/03/2022, 5:53 PMthdxr
03/03/2022, 5:53 PMRoss Coundon
03/03/2022, 5:54 PMRoss Gerbasi
03/03/2022, 5:54 PMthdxr
03/03/2022, 5:54 PMthdxr
03/03/2022, 5:54 PMthdxr
03/03/2022, 5:56 PMnpx esbuild --metafile=meta.json --bundle --format=cjs --sourcemap --platform=node --target=node14 --outfile=out.js src/node/function.ts
Run that replacing the src/node/function.ts with your function. Then check meta.json to see if inputs
looks correctRoss Gerbasi
03/03/2022, 5:58 PMRoss Gerbasi
03/03/2022, 5:59 PMroute.ts
file I see Building {file}
then Done Building {file}
However if i change anything in a file that is imported by route.ts
i do not see buildingDerek Kershner
03/03/2022, 6:00 PMnode_modules
, just in case that is what you are doing, but my experience matches @Ross Coundon’s otherwise.Ross Gerbasi
03/03/2022, 6:00 PMsrc
folder...Derek Kershner
03/03/2022, 6:01 PMRoss Gerbasi
03/03/2022, 6:24 PMDebug SST Start
It just says Debugger Attached
for a few seconds then gives me the message
Add the sst.json config file in your project root to get started. Or use the create-serverless-stack CLI to create a new project.
So maybe its just having trouble finding files in general here.. 🤷♂️Ross Gerbasi
03/03/2022, 6:26 PMsst start
in bash instead of fish will change anything with building...Ross Coundon
03/03/2022, 6:42 PMRoss Gerbasi
03/03/2022, 6:43 PMRoss Coundon
03/03/2022, 7:06 PMFrank
sst start
directly from ur terminal in bash, you don’t get this error right?
Add the sst.json config file in your project root to get started. Or use the create-serverless-stack CLI to create a new project.
But changing dependencies does not trigger a rebuild right?Ross Gerbasi
03/03/2022, 11:57 PMsst start
forks fine in fish
or bash
. VSCode launcher for debugging only seems to work wish bash
within vscode. Using fish
shell with VSCode launcher results in locating sst.json
error
Neither fish
or bash
help with my TS dependency issue, I cannot get a dependent file to trigger a route rebuild.
As mentioned earlier if you wanna hop on a call and check it out I can just show ya quick.Ross Gerbasi
03/04/2022, 5:00 PM