Uploaded image for project: 'Magnolia CLI npm module '
  1. Magnolia CLI npm module
  2. NPMCLI-84

Add "light-module"-placeholder to component/page mgnl-cli-prototypes

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.0.7
    • Fix Version/s: 2.1.0
    • Labels:
      None
    • Sprint:
      Basel 86
    • Story Points:
      2

      Description

      Currently create-component and create-page copy the (optionally customized) prototype and replace the containing "__name__" placeholder with the passed name argument. When using customized mgnl-cli-prototypes, a placeholder for the name of the corresponding light module could be useful as well. E.g. for having light-module-relative import paths or adding prefixes/suffixes with the name of the light-module.

      The logic for this should currently be in "@magnolia/cli/lib/createComponent.js#65", where only the "_name" placeholder is passed to the _createFromPrototype.create() function.

      edit: To avoid ambiguity, it might be a good idea to rename "mgn-cli-prototypes" to "blueprints". I just realized this, when writing this ticket, as "prototype" in magnolia now has two different meanings.

        Attachments

          Activity

            People

            • Assignee:
              rkowalski Robert Kowalski
              Reporter:
              mmueller Matthias Müller
            • Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Date of First Response: