Magento 2: Approximating Local Code Pool Overrides Not sure if I like the idea of this becoming a common practice, but if you know your composer autoloading you can replace any class in Magento with a version of your own.
astorm
Knockoutjs context debugger Chrome extension for peeking at a node’s KnockoutJS context. Useful if you’re doing frontend Magento work and hewing to their view of the world. via Daniel Sloof.
astorm
Another javascript debugging snippet for the intrepid Magento 2 javascript programmer. The Magento_Ui/js/core/app RequireJS module/application/program is an important part of Magento 2’s UI Component system. This is the program that registers KnockoutJS views and makes them available for use in the (custom to Magento 2) Knockout.js [...]
astorm
Magento 2: Syncing Backend and Frontend State/Cache Haven’t had time to check this out yet, but this is a far more cogent explaination of Magento 2’s mysterious sections.xml than anything I’ve seen so far.
astorm
If you've dug into pestle, my command line PHP framework and Magento code generation tool, you've probably noticed it wasn't super friendly to use pestle based code in your own PHP projects. That changes starting today. Pestle is now a packagist library, which means
astorm
When I started work on pestle’s Magento 2 code generation, I deliberately left the the <preference/> feature of Magento’s di.xml files off the list of commands. This was, in short, to help encourage the use of plugins over preferences. i.e. to encourage developers to use the system that allowed multiple extensions to [...]
astorm
This one’s more interesting than it is useful (or its main use is as a debugging exercise), but while I was working on a UI Component tutorial I wanted to turn off the XSD validation for ui_component files. It turns out there’s a dedicated object that can control whether the XSD validations are applied [...]
astorm
For folks using pestle, my PHP command line frameworking + Magento code generation tool, I’ve just added a selfupdate command. This will make a backup of your current version, grab the latest version, and update your local copy (permissions allowing, of course) $ pestle.phar selfupdate Downloaded to /private/tmp/pestle_DZOXou [...]
astorm
If you're new to PHP, you may find the concept of autoloading a little confusing. When PHP first introduced classes, there was no defined way to load class definition files — end-user-programmers were expected to use require and include to pull in the classes definitions
astorm
If you're following along over on the Pulse Storm blog, you'll know we've just released Commerce bug 3.1. This is mostly a bug fix/Magento 2.1 compatibility release, but there are a few new features hidden beneath the surface.
astorm
One of the big changes for Magento 2 developers is the introduction of a formal, "semantic versioning" system to the platform. If you're a Magento developer and this comes as news to you, don't feel bad. Although there's been plenty of talk about the
astorm
I'm happy to announce the immediate availability of the Pulse Storm Launcher UI enhancement for WordPress, including integrations with WooCommerce and WP eCommerce. The source is currently available on GitHub, and I'm hoping to carve out some time to get it submitted to the
astorm
I’m knee deep in a rewrite of No Frills Magento Layout for Magento 2 – I know the systems well enough to use them, but I’m still coming up to speed on the underlying object implementations. This is important, since my approach in No Frills is Here’s how you’d do this in PHP, here’s how to do the same [...]
astorm
Although the technique still works, various members of Magento’s engineering team have discouraged using Magento 1’s <action method="..."/> syntax to call methods on blocks from layout update XML files. <block ...> <action method="addTab"> <argument name="name" [...]
astorm
Magento 2 module creator and code generator | Mage2Gen Haven’t had a chance to check this out yet, but it looks like another Magento 2 module generation tool. This one seems to be an “everything and the kitchen sink” approach (vs. pestle which lets you build only the parts you need) but that approach does mean you get a [...]
astorm
Can’t Add a new UI Component Type · Issue #5647 · magento/magento2 An interesting side effect of the new XML schemas – the definition.xml files for UI components have their top nodes locked down, which means developers can’t add their own UI component types.
astorm
Formatting Dates in Magento Javascript If you’re doing any work in Magento’s RequireJS based javascript modules and see a dateFormat string defaults: { dateFormat: 'MMM d, YYYY h:mm:ss A' }, Chances are its a Moment.js date format string. You can pull in the main moment function via a RequireJS shim define(['moment'], [...]
astorm
Demystifying Plugins (MageTitans Italy 2016) Concise explanation of the code involved in using a Magento 2 Plugin to change core system behavior, with the talk over here if you’re the sort who likes context.
astorm
I’ve been digging through Magento’s UI Components this week and hit a stumbling block. The main KnockoutJS template that kicks off rendering (vendor/magento//module-ui/view/base/web/templates/collection.html) looks like this <each args="data: elems, as: 'element'"><render [...]
astorm
I just updated pestle with a new magento2:generate:ui:grid command. Magento 2.1+ only, not likely to be ported backwards to the 2.0.x branch. A longer article over on alanstorm.com is forthcoming, but here’s the quickie version. Here’s the arguments to use to create a UI Component Listing. $ pestle.phar [...]
astorm