Categories


Archives


Recent Posts


Categories


Open Magento 2 Technical Questions

astorm

Frustrated by Magento? Then you’ll love Commerce Bug, the must have debugging extension for anyone using Magento. Whether you’re just starting out or you’re a seasoned pro, Commerce Bug will save you and your team hours everyday. Grab a copy and start working with Magento instead of against it.

Updated for Magento 2! No Frills Magento Layout is the only Magento front end book you'll ever need. Get your copy today!

A quick, semi-regular roundup of open Magento 2 technical questions.

How to use ui_component

Magento introduces a new layout handle XML node named uiComponent that lets you insert specific user interface elemnts into your application. Unfortunately, documentation on how to use this is woefully incomplete. The documentation that does exist looks like it will be useful to anyone who’s already familiar with the system, but there’s nothing there that gets people familiar with the system.

I’ve got a few questions on this on the Magento Stack Exchange, but none with answers that come close to what a new user would need to get started with a UI Grid in Magento 2. This one is just the latest

Magento 2: UI Listing Component for a CRUD Model

Setting up a Magento 2 Admin Route

As time went on in Magento 1, it became pretty clear that the core code wanted module developers to hook their admin routers into the adminhtml router. This all came to a head with a recent security patch that forced the issue – non adminhtml stopped working.

Magento 2 has a similar issue – some core routes hook into the adminhtml route, others setup their own frontname. It’s not clear if there’s similar negative consequences in Magento 2 for modules that use their own custom named route instead of hooking into adminhtml.

Setting up an Admin Route in Magento 2

RequireJS Integration

I’m just starting to get into how Magento has implemented their RequireJS based system. Somehow Magento’s RequireJS system is able to recognize module names and produce the correct URL. I’m curious as to where this happens in Magento 2.

How/Where does Magento Convert a RequireJS module Name into a URL?

Role of the exclude tag in view.xml files

Magento’s theme view.xml files have an exclude tag – but it’s not clear what those exclude nodes exclude from what. (Although Vicky does has a nice rundown of the code involved)

What does the “exclude” Tag in Magento 2’s view.xml file do

URLs Must be Three Characters Long. Why?

The XSD validation of XML files in Magento 2 is great. However, it’s not always clear why some of the rules are in place, and not even Magento’s architects seem to know.

Why Does Magento 2 Force URLs to be 3+ Characters

Running setup:di:compile only for a single module

Part of deploying a Magento 2 system to production includes pre-generating a number of class files with the setup:di:compile command. This command also performs some basic validation on your code. This command also takes between 2 – 10 minutes to run, which makes finishing up a module that violates one of its lints extremely tedious. Being able to run the command for only a subset of modules (i.e. the ones you’re working on) would be a welcome improvement.

Magento 2: Run setup:di:compile only a Specific Module?

Reading Configuration Files in Magento

The Magento 2 documentation still lacks clear instructions on how a module developer can read Magento’s configuration files. The absence of instructions on how to perform a task that was so simple in Magento 1 is baffling.

Magento 2: How Should Module Developers Read their Own Configuration Files

Minimal Composer File

With Magento Connect’s replacement (Magento Marketplace) still shrouded by a cloud of mystery, it’d be nice if the community could come up with minimal basic composer file that would let developers install modules into their system.

This should be relatively simple, since Magento started used registration.php for components, and I’ll likely answer it myself in the next week or two if no one steps up.

Magento 2: Minimum Composer File

How does Magento 2 Send Email

Does Magento 2 have support for third party transactional email systems like Amazon SES or Mandril?

Magento 2: Sending Email Programmatically

Copyright © Alan Storm 1975 – 2019 All Rights Reserved

Originally Posted: 25th January 2016