question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Some mechanism to have the raw definition of the schema

See original GitHub issue

Hi guys, would be possible to expose a method or property to have the raw data like

const schemaA = new SimpleSchema({ name: { type: String }});
const definition = schemaA.definition // => return the { name: { type: String } }

Issue Analytics

  • State:open
  • Created 3 years ago
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
aldeedcommented, Jul 16, 2020

Keeping a reference to both the original schema obj and the expanded clone could increase memory consumption quite a bit. (I assume at least some of the original obj is being garbage collected right now.) If anyone implements this, it should be opt-in with a constructor option, unless you can prove that memory use is unchanged.

In the constructor it might look something like this:

if (keepRawSchemaRef) {
  this.rawSchema = schema;
}
1reaction
coagmanocommented, Jul 12, 2020

Should be relatively simple, if you want to try making a PR?

Read more comments on GitHub >

github_iconTop Results From Across the Web

W3C XML Schema Definition Language (XSD) 1.1 Part 2
A small collection of functions, relations, and procedures associated with the datatype. Included are equality and (for some datatypes) order ...
Read more >
Schema-on-Read vs Schema-on-Write - Blog | luminousmen
Any data management system belongs to one of two types. The first one is schema-on-write. Schema-on-write. Probably a lot of you have ...
Read more >
Handling schema for Power Query connectors - Microsoft Learn
The simplest approach is to hardcode a schema definition into your connector. This is sufficient for most use cases. Overall, enforcing a schema ......
Read more >
Schema Definition Export and Import - RabbitMQ
Definitions are stored in an internal database and replicated across all cluster nodes. Every node in a cluster has its own replica of...
Read more >
Schema Migrations and Patches - Marten
sql." Today, the migration mechanism covers: Creates any missing database schemas; Document storage tables, "upsert" functions, and any configured indexes -- ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found