How to use ember-table with Ember 2.3


#1

Greetings!

I have a pretty big problem since my job is using an older version of Ember, but wants to convert to a newer version. The application is using ember-table quite a lot, BUT ember-table’s row-array.js extends ArrayController which is providing me with problems and a small head-ache.

I have installed all the legacy-addons in order to understand the problem, but it seems like these does not even work for ArrayController since the Ember Inspector returns the same error no matter what. It’s really important to use these bloody tables in our project and I can’t give you too much code since it’s confidential. Anyone able to provide me with some help?

The error message: Uncaught TypeError: Cannot read property ‘extend’ of undefined

The code returned from Inspector: define(‘ember-table/controllers/row-array’, [‘exports’, ‘ember’, ‘ember-legacy-controllers/array’], function (exports, _ember, _emberLegacyControllersArray) { ‘use strict’;

exports[‘default’] = _ember[‘default’].ArrayController.extend({ itemController: null, content: null, lastItem: null,


#2

You likely need to add ArrayController to the Ember namespace for it to be used by Ember Table.

But this is likely not going to be enough anyway as Ember Table relies on ListView which doesn’t support Ember 2.0. There’s an ongoing to effort to have Ember Table supporting Ember 2.0. You can follow the progress here https://github.com/Addepar/ember-table/pull/374