retejs / stage0-render-plugin

3 stars 6 forks source link

Component names with space #6

Closed renjfk closed 5 years ago

renjfk commented 5 years ago

I gave this a shot however didn't work since my components have space(s) in names. I would suggest using a class name transformer just like alight plugin had as following:

function toClassName(str) {
    return str.toLowerCase().replace(/ /g, '-')
}
trsh commented 5 years ago

Can u drop a codepen example of what is not working? Didn't get it. @renjfk

renjfk commented 5 years ago

Well I switched to react render and unfortunately don't have time to reproduce issue but just as a hint you can take a look at here https://github.com/retejs/react-render-plugin/blob/master/src/utils.js and maybe ask author why was this implemented in the first place.