allfix
allfix

Reputation: 52

how to set model extend in models.json?

I use new loopback, in my models.json :

"customer": { "options": { "extend": "User" }, "properties": {} }

But after run and explore, the customer model isn't extend user.

Upvotes: 0

Views: 694

Answers (1)

Raymond Feng
Raymond Feng

Reputation: 1536

"base" should be used instead of "extend". See docs.

"user": {
  "options": {
    "base": "User",
 },
 "properties": {}
}

We could consider to support both "base" and "extend".

Upvotes: 1

Related Questions