Comments (8)
@wrummler thanks for the contribution! Check v2.0.6
from ngx-sortablejs.
@wrummler ahem, that sounds weird. AOT build usually cannot break a non-AOT one, from what I know. Could you, please, tell more about your environment?
- Webpack or systemjs and the version of the one
- angular version
- angular-sortablejs version
It would also help to have a public repo where the issue could be reproduced
from ngx-sortablejs.
I applied the README instructions to the quickstart seed and got the same error as #44. Repo here.
I don't think this is a AoT/non-AoT issue at this point. I think these issues boil down to 6b7a969 introducing the requirement that the user's module loader understand ES2015 modules. For example, my non-AoT app is a very plain Electron/Angular setup (derived from electron-forge init
's Angular template) that simply uses Node's require
to load modules. When it sees export
, it doesn't recognize the token because Node doesn't yet provide built-in support for ES2015 modules. Similarly, when SystemJS sees it in e.g. the quickstart repo linked above, apparently it's trying to grab traceur
to transpile it on-the-fly. This is part of the quickstart behavior:
Unable to load transpiler to transpile http://localhost:3000/node_modules/angular-sortablejs/dist/index.js
I made another branch that attempts to work around the issue by including configuration for systemjs-plugin-traceur
. It eliminates the error in that example repo, but the behavior of the simple example included from this project's README seems incorrect, since the "See the result" items are not updated when the dragged items are.
Also, this workaround isn't available for my actual project, since we're not using SystemJS (or Webpack etc), just Node's require
in Electron.
from ngx-sortablejs.
I updated the issue title. Please consider this a suggestion to remove the requirement by including a CommonJS-compatible main
entry in the distributed package.json and allowing ES2015 module users (e.g. those using AoT with Rollup) to configure their loader to point to a separate ES2015 build file also included with the distributed package. Thanks.
from ngx-sortablejs.
that could be then the same issue as this one #44. You are right
from ngx-sortablejs.
@wrummler could you please check if v2.0.5 fixes the issue?
from ngx-sortablejs.
fixed the second issue too. For some reason the change detection trigger was not done
from ngx-sortablejs.
@smnbbrv Thanks, 2.0.5 fixed it for me.
Also, I don't have an AoT setup handy to double-check, but I think that AoT/rollup users can still use this new/reverted build if they update their rollup-config.js appropriately in the object passed to the invocation of the commonjs
plugin in the plugins
array. (It's been a long time since I used AoT, so YMMV.)
from ngx-sortablejs.
Related Issues (20)
- Issue with dragging last item in last row HOT 1
- Mobile reordering is spotty
- Support Angular 12 HOT 9
- Plugins swap not working, please help me to custom add swap function.
- Angular 6 issue compatibility HOT 3
- Does not work with Angular Material Grid List
- Unmount Plugins on ngDestroy HOT 1
- Support Angular 13 HOT 18
- Module '"ngx-sortablejs"' has no exported member 'SortablejsOptions'.ts in Angular 12 HOT 4
- Publish an Ivy distribution HOT 1
- Unable to evaluate this expression statically HOT 2
- Incorrect order after adding an element in array HOT 3
- Escape to cancel drag/drop operation
- this libray found not support Anglar13 any body Idia about that HOT 11
- Generating browser application bundles (phase: setup)...Processing legacy "View Engine" libraries
- Make hold to start dragging
- How to set a boundary to the drag operation
- npmjs does not show any helpful text for the package
- Angular 11 simple sorting not working
- Compatibility with the Ivy view engine HOT 18
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ngx-sortablejs.