Comments (6)
Oh that would actually be really awesome!
I am not quite into Angular, but I guess Angular 2 is already used a lot right? Also if its already a RC I guess we are fine to just use that one. Should not change much right?
I would really love to see a TypeScript example if possible, but yet of course it is up to you. All 3 would be best, if 2 I would go with TypeScript, but it's also fine to just have the basic JS examples.
I am really looking forward to see your PR soon :)
from fela.
Ok nice :).
I just finished diving into a real live example with a tiny react application
and I might need to write some helper or think of something like this mapStylesToProps
thing and what the corresponding thing in Angular 2 would be.
It will take me sometime but I will provide it :)
Since in my company we are sometimes forced by the customer to use Angular 2 instead of React I want to have at least the styling independent :)
from fela.
Status / Todo
- π Pull Request = ready to merge
1. Typescript Angular 2 Example
- π΅ Typings
- π Basically done and working.
- π Write Interfaces with Exports for all classes/methods in index.d.ts
- π΄ TODO-POSTMERGE:
- after merge of #67 and deploy to npmjs increase version of
/examples/angular2/typescript/package.json
fela dependency so that the typescript bindings can be used.
- after merge of #67 and deploy to npmjs increase version of
- π΅ Example
- π Code Example is done and working see examples/angular2/typescript
- π Documentation see UsageWithAngular2TypeScript.md
- πΆ Needs Clarification / Action Items
- β
index.d.ts location => all ok
The question is: Is thispackages/fela/
the right place to put it?Or do you want it to place somewhere else and configure your buildchain?
- β
SystemJS Loader Problems because of require => won't fix
The SystemJS Loader used for Angular2 has problems when trying to load thenode_modules/fela/index.js
. It contains a require call todist/fela.js
. I will provide documentation on how to come around that, but wouldn't it be nicer if thepackage.json
would point to"main": "./dist/fela.js"
directly?
- β
gitbook plugins => included in PR #67
Can you install the gitbook-plugin-advanced-emoji for the documentation on fela.js.org so that I can use emojis in my docs, thx.
- β
index.d.ts location => all ok
2. Plain JS Angular 2 Example
- π΅ Example
- π Code Example is done and working see examples/angular2/javascript
- π Documentation done, see UsageWithAngular2JavaScript.md
3. DART Angular 2 Example
- JS Bridge
- So Dart cannot natively use JavaScript and you need to use some kind of bridge. I tried to do so in fela_js_bridge.dart
- This does not work currently and I am a little helpless here since the only example is the ChartJS Bridge
- So Dart cannot natively use JavaScript and you need to use some kind of bridge. I tried to do so in fela_js_bridge.dart
- Ugliness
- I don't know who really uses Dart but when you always have to write your own dart bridge for every library from the web I think you are doomed.
- Secondly: Dart does not seem to have nice syntax for "Json-Like-Objects" and the rule-set now looks like s++t. See here: app_component.dart
- PackageManager
- Of course dart uses its own package management so for now you are doomed to use Fela from CDN. Or you publish a dart package which you have to maintain :(
useful dart js links
* https://github.com/google/chartjs.dart
from fela.
@rofrischmann I am done for now. Typescript and ES6 Examples + Documentation is done.
We just need to clarify the stuff above :)
from fela.
FYI: Angular 2 Dart - Work in Progress
- Example Angular2 Dart
- UsageGuide
from fela.
With the release of 1.2 we should be able to use Fela with Angular. I will close this issue for now, as the Dart example does not seem to be fixed too soon. I will yet try to bring some details back into the documentation, but I had to strip it off to be conform to the React/Inferno docs which only cover React/Inferno specific stuff but do not cover Fela configs at all (which was part of the Angular docs as well).
from fela.
Related Issues (20)
- react-fela providers only accept single element children HOT 2
- Use fela with ReactDOM.createPortal on a different window HOT 1
- fela-plugin-responsive-value doesnβt handle nested objects
- Fela doesnβt hydrate CSS custom properties HOT 1
- fela-plugin-multiple-selectors doesnβt extend styles
- renderStatic doesnβt handle nested objects
- Document targetDocument
- renderToNodeList not exported in react-fela/index.d.ts HOT 1
- Typescript plugin doesn't extend style definition HOT 5
- Native ESM support HOT 5
- renderStatic not applying some plugins HOT 6
- Missing changelog for 11.5.x & 11.6.x HOT 2
- Rehydration of `&` selectors HOT 10
- Rules are mixing between components when we switch between pages. HOT 1
- Typescript interface for renderer configuration (IConfig) misses some options HOT 2
- Transform key as array ignored HOT 5
- [Feature] Add bindings for solid-js HOT 1
- Fail to set backgroundImage fallback value HOT 3
- Bug: no fela styles on saved page HOT 1
- react-native: no style export in useFela hook HOT 2
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 fela.