DevExtreme icon indicating copy to clipboard operation
DevExtreme copied to clipboard

Add TS configuration and NX project for metadata

Open IlyaKhD opened this issue 6 months ago • 1 comments

Mutation helpers

[
  {
    "kind": "remove",
    "uid": "/card_view:Toolbar",
  }
]

➡️

  removeMembers(/\/card_view:Toolbar/),

[
  {
      "kind": "remove",
      "uid": "ui/form:dxFormSimpleItem\\.(editorOptions|editorType)"
  },
  {
      "kind": "add",
      "uid": "ui/form:dxFormSimpleItem.editor",
      "types": [
          {
              "kind": "custom",
              "name": "WidgetFactory",
              "params": {
                  "factory": "FormItemEditor",
                  "componentNameProp": "editorType",
                  "componentConfigProp": "editorOptions"
              }
          }
      ]
  }
]

➡️

  ...replaceWithWidgetFactory({
    uid: 'ui/form:dxFormSimpleItem',
    from: {
      componentNameProp: 'editorType',
      componentConfigProp: 'editorOptions',
    },
    to: {
      factoryName: 'FormItemEditor',
      newProp: 'editor',
    }
  })

[
  {
      "kind": "add",
      "uid": "ui/popover:dxPopoverOptions.toolbarItems",
      "types": [
          {
              "kind": "array",
              "itemTypes": [
                  {
                      "kind": "memberRef",
                      "uid": "ui/popover:ToolbarItem"
                  }
              ]
          }
      ]
  }
]

➡️

  addMember({
    uid: 'ui/popover:dxPopoverOptions.toolbarItems',
    types: [array(memberRef('ui/popover:ToolbarItem'))],
  })

IlyaKhD avatar Jun 19 '25 20:06 IlyaKhD

You may want to check my old draft https://github.com/pomahtri/DevExtreme/compare/fae63049bad2b896d4b45c983e05bc1358e8d45a...refactor/nx_projects/metadata

pomahtri avatar Jun 20 '25 05:06 pomahtri

You may want to check my old draft pomahtri/[email protected]/nx_projects/metadata

Yes, I was just about to ask for it, thnx 🤝

The aim of this PR is to use TypeScript metadata configurations, but I agree we should make it more aligned with the NX way, since we have the opportunity

IlyaKhD avatar Jul 07 '25 09:07 IlyaKhD