create account

RE: My Busy.org November and December report: Server-Side Rendering, AMP, and a lot more by sekhmet

View this thread on: hive.blogpeakd.comecency.com

Viewing a response to: @superoo7/re-sekhmet-my-busy-org-november-and-december-report-server-side-rendering-amp-and-a-lot-more-20180102t213331752z

· @sekhmet · (edited)
$0.44
We use .less files (due to the fact we use `antd` and we have to use Less to modify it), and just use webpack import's to import them. After we build our app, we have .html files that includes all stylesheets. This file is then used as a template on the server.

If you want to use `styled-components` on the server you have to wrap your entire application in `ServerStyleSheet` collector that would collect all of your styles from components. After it's done you can just retrieve normal style tags from it and add it to your page. Take a look here: https://www.styled-components.com/docs/advanced#server-side-rendering
👍  , , ,
properties (23)
authorsekhmet
permlinkre-superoo7-re-sekhmet-my-busy-org-november-and-december-report-server-side-rendering-amp-and-a-lot-more-20180102t231722640z
categoryutopian-io
json_metadata{"tags":["utopian-io"],"community":"busy","app":"busy/2.2.0"}
created2018-01-02 23:17:24
last_update2018-01-02 23:17:42
depth2
children3
last_payout2018-01-09 23:17:24
cashout_time1969-12-31 23:59:59
total_payout_value0.439 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length620
author_reputation1,353,498,428,522
root_title"My Busy.org November and December report: Server-Side Rendering, AMP, and a lot more"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id26,652,536
net_rshares49,842,431,065
author_curate_reward""
vote details (4)
@superoo7 ·
I had been using sass for a while. Transition to `styled-component` took me sometime to get used to it haha.
properties (22)
authorsuperoo7
permlinkre-sekhmet-re-superoo7-re-sekhmet-my-busy-org-november-and-december-report-server-side-rendering-amp-and-a-lot-more-20180102t231931073z
categoryutopian-io
json_metadata{"tags":["utopian-io"],"app":"steemit/0.1"}
created2018-01-02 23:19:30
last_update2018-01-02 23:19:30
depth3
children2
last_payout2018-01-09 23:19:30
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length108
author_reputation27,763,618,634,121
root_title"My Busy.org November and December report: Server-Side Rendering, AMP, and a lot more"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id26,652,809
net_rshares0
@sekhmet ·
$0.40
I like the way [styled-jsx](https://github.com/zeit/styled-jsx) works. It feels like normal CSS but has some great features (scoped to current component, works on SSR).

If you are working on new app and want to have SSR I recommend checking out [Next.js](https://github.com/zeit/next.js).
👍  , ,
properties (23)
authorsekhmet
permlinkre-superoo7-re-sekhmet-re-superoo7-re-sekhmet-my-busy-org-november-and-december-report-server-side-rendering-amp-and-a-lot-more-20180102t232607428z
categoryutopian-io
json_metadata{"tags":["utopian-io"],"community":"busy","app":"busy/2.2.0"}
created2018-01-02 23:26:12
last_update2018-01-02 23:26:12
depth4
children1
last_payout2018-01-09 23:26:12
cashout_time1969-12-31 23:59:59
total_payout_value0.402 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length289
author_reputation1,353,498,428,522
root_title"My Busy.org November and December report: Server-Side Rendering, AMP, and a lot more"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id26,653,633
net_rshares45,839,754,141
author_curate_reward""
vote details (3)
@superoo7 ·
Currently I am still using Express or Koa for SSR haha.

I am also looking on this [jss](https://github.com/cssinjs/jss) where Material-UI is using this.
properties (22)
authorsuperoo7
permlinkre-sekhmet-re-superoo7-re-sekhmet-re-superoo7-re-sekhmet-my-busy-org-november-and-december-report-server-side-rendering-amp-and-a-lot-more-20180103t005105613z
categoryutopian-io
json_metadata{"tags":["utopian-io"],"links":["https://github.com/cssinjs/jss"],"app":"steemit/0.1"}
created2018-01-03 00:51:06
last_update2018-01-03 00:51:06
depth5
children0
last_payout2018-01-10 00:51:06
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length153
author_reputation27,763,618,634,121
root_title"My Busy.org November and December report: Server-Side Rendering, AMP, and a lot more"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id26,664,458
net_rshares0