New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use ionicons as web-components in doc site #626

Open
juanmiguelbesada opened this Issue Oct 19, 2018 · 2 comments

Comments

Projects
None yet
2 participants
@juanmiguelbesada

juanmiguelbesada commented Oct 19, 2018

Hi guys.

I'm a bit confused. I was watching the ionicons website https://ionicons.com/ and you promote to use web-components (and I really do agree).

But, checking the website I realize that you are not using the ion-icon webcomponent.

<i class={'ion ion-' + icon.icon}></i>

Is it in purpose or do you missed it?

Anyway I think is not cool that you dont practise what you preach.

Glad to send a PR if you want.

@peterennis

This comment has been minimized.

peterennis commented Oct 19, 2018

@juanmiguelbesada
Ionicons are used in ionic core.
I understand the design allows for backwards compatibility with other ionic versions.
Here is a test example extending them as a component: https://aesvg.adaept.com/
Code: https://github.com/peterennis/ae-svg-components/tree/master/src/ae-icons-component
and
https://github.com/peterennis/ae-svg-components/blob/master/src/index.html
I have been testing this for Ionic 4 development.

Here is the standalone stencil component: https://github.com/adaept/ae-ionicons

Maybe it helps with what you want to do.
Feedback welcome.

@juanmiguelbesada

This comment has been minimized.

juanmiguelbesada commented Oct 22, 2018

hi @peterennis

I didn't mean about how to use ionicons as a web component. Just that the docs site (https://ionicons.com/) is not using the icons as web-component but as a font.

If you check the source code, you will realize that they are using

<i class="ion ion-add-circle-outline"></i>

instead of

<ion-icon name="add-circle-outline"></ion-icon>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment