'Is there anyway working with schemas in Deno?
I am trying to store and work with a similar to following structure data using Deno and MongoDB.
[
{
id: "AAPL",
stockData: [
{ date: 1634601600, summary: [Object] },
{ date: 1634688000, summary: [Object] },
{ date: 1634774400, summary: [Object] },
{ date: 1634860800, summary: [Object] }
]
},
{
id: "MSFT",
stockData: [
{ date: 1634601600, summary: [Object] },
{ date: 1634688000, summary: [Object] }
]
}
]
And [Object]
is something like:
{
date: "1646956800",
summary: { open: 287.96, high: 289.51, low: 279.43, close: 280.07, volume: 27209330 }
}
As Deno is new and I know there is no compatibility with Deno and Mongoose at the moment, I have some questions:
- Is there any alternative to Mongoose for Deno or any better way to work with schemas?
- If I want to do a big project should I stop working with Deno and return to using NodeJS at the moment?
- Can I convert my Deno code to NodeJS-TypeScript code or it is better to rewrite it in JavaScript?
I am a mediocre programmer and new in web development. I am trying to write my first real/commercial project and I don't want to get stuck because of lack of abilities in Deno, also want to use the latest technology and don't want to rewrite the project with a new technology after I completed it. So I don't know should I keep my project using Deno or rewrite it to NodeJS and forget the Deno?
Solution 1:[1]
You can use the mongoDriver for Deno : https://deno.land/x/mongo. It is not the only one available on deno.land/x, you can make a search from deno.land website.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | Wax |