api-platform / api-platform/create-client

Vue generators produce invalid names for scoped slots

Offen
#380 4 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
TypeScript
Sterne
376
Forks
132
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

**Description**
Vue generators produce invalid names for scoped slots
For example:
```vue



{{ book["@id"] }}





```

It show this error: `Illegal '/' in tags.vue(22)`

**How to reproduce**
Run the `yarn test-gen` command and look at the `{quasar|vuetify|vue}/components/[foo]/[FooList].vue` components

**Possible Solution**
The named scoped slots use the property names inside the table components to create the table cells and columns.

If we replace the slash with another character, we should make sure the slot name match the real property name from the API.
We need to check how the properties received from the API are named.

Another solution, maybe, would be to use variable for slot names.
But that would mean receiving them as props or declaring them in the script section, but it's not ideal.

Do you have an idea @dunglas ?

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.