Why does the guide in the Best Practices use Serve...
# guide
j
Why does the guide in the Best Practices use Serverless Framework for the backend APIs and only uses SST for the infrastructure repo? There is no rationale given for this that I can see and I'm finding it confusing since I've just been using SST for everything up until this point. Is it just to demonstrate that you can use it or is there an advantage to it? If it is just a choice thing, then on each section of the Best Practices it should show how to make it work in SST as well, as I'm wanting to follow the these best practices and build a production ready, scalable app, but have to try to decipher the yaml serverless bits.
f
Hey @jamlen, sorry for the confusion. The best practice guide was originally written in Serverless Framework a while back. We will be updating it to use SST, most likely in January.
cc’ing @Jay (our main author for the guide)
j
Thanks Frank! I'm going to be starting to build my main application in January so may ping when I'm confused!
Quickly, is there a distinct benefit to using both frameworks like this in the guide? I'd prefer to stick to just SST
k
@jamlen, I use only SST for my app and found it to be all I need, the only thing I could think of that you would benefit from using Serverless Framework are some plugins that SST does not support yet.. But in many cases those are easily reproduced with some CDK constructs + some custom lamdba code. SST in my opinion is way more powerful than Serverless Framework because you get the benefit of using the full CDK
j
Thanks @Kujtim Hoxha that is what I was hoping for! How do you do the cross-stack reference import in SST/CDK from https://serverless-stack.com/chapters/cross-stack-references-in-serverless.html
in the yaml its
tableName: !ImportValue ${self:custom.sstApp}-ExtTableName
k
So for my usecase I simply have the other stack as a dependency something like :
You could also just pass the table as a dependency here.
j
Ahh ok, so not with them split into a separate repo then.
k
Nope I use a monorepo
j
Yeah that's what I'm planning on using too.
k
Makes life easier 😂