{"action":"closed","issue":{"url":"https://api.github.com/repos/japgolly/scalajs-react/issues/406","repository_url":"https://api.github.com/repos/japgolly/scalajs-react","labels_url":"https://api.github.com/repos/japgolly/scalajs-react/issues/406/labels{/name}","comments_url":"https://api.github.com/repos/japgolly/scalajs-react/issues/406/comments","events_url":"https://api.github.com/repos/japgolly/scalajs-react/issues/406/events","html_url":"https://github.com/japgolly/scalajs-react/issues/406","id":250789043,"number":406,"title":"mkString for TagMod","user":{"login":"japgolly","id":202935,"avatar_url":"https://avatars2.githubusercontent.com/u/202935?v=4","gravatar_id":"","url":"https://api.github.com/users/japgolly","html_url":"https://github.com/japgolly","followers_url":"https://api.github.com/users/japgolly/followers","following_url":"https://api.github.com/users/japgolly/following{/other_user}","gists_url":"https://api.github.com/users/japgolly/gists{/gist_id}","starred_url":"https://api.github.com/users/japgolly/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/japgolly/subscriptions","organizations_url":"https://api.github.com/users/japgolly/orgs","repos_url":"https://api.github.com/users/japgolly/repos","events_url":"https://api.github.com/users/japgolly/events{/privacy}","received_events_url":"https://api.github.com/users/japgolly/received_events","type":"User","site_admin":false},"labels":[{"id":259920947,"url":"https://api.github.com/repos/japgolly/scalajs-react/labels/could","name":"could","color":"fbca04","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2017-08-16T23:29:33Z","updated_at":"2017-09-21T00:23:01Z","closed_at":"2017-09-21T00:23:01Z","author_association":"OWNER","body":"It's quite common to render a sequence of elements with some kind of separator between them.\r\nI should add a helper to scalajs-react for this.\r\n\r\nIn my project I'm using:\r\n```scala\r\nimport japgolly.microlibs.stdlib_ext.StdlibExt._\r\n\r\ndef renderSeq[A, B](as: TraversableOnce[A], separator: TagMod)(renderEach: A => B)(implicit g: B => TagMod): VdomTag =\r\n  <.span(\r\n    TagMod.fromTraversableOnce(\r\n      as.toIterator\r\n        .map(g compose renderEach)\r\n        .intersperse(separator)))\r\n```"}}
{"actor":{"display_login":"japgolly"}}