Advanced Angular elements web components tutorial with angular 7/6

preview_player
Показать описание
In this advanced angular6/7 elements web components tutorial, I have demonstrated how to convert your existing angular component to a advanced standard javascript based web components using angular element ( used angular-cli and es6).

====================================================

=====================================================
Рекомендации по теме
Комментарии
Автор

Thanks for watching everyone!! Please add your comment how much you like this video. You can also recommend some subject for the next video to me.

BlackBoxTech
Автор

Thanks for sharing. Try to make video without any background music.

sqlguruji
Автор

Thanks for this excellent video. The web components I have been creating using the techniques you outlined work great inside vanilla html files.

I have been struggling to figure out how to import my web components into a new angular app. It would be very useful to port complete web components into new angular projects.

Do you mind creating a video demonstrating how to import this web component you created inside a new Angular 8 project?

NormGlomski
Автор

Thanks for sharing. Try to make video without any background music. With background music I was feeling like learning angular in cooking style.

pushkarrathod
Автор

Hey, nice video, I'll say at 00:28 when showing text, change the background color to black, it will look better.

ShubhamAkolkarx
Автор

I was getting a blank page because it wasn't building correctly. Fix, tsconfig.json in the compilerOptions should bet set as "target": "es2015". Also make sure your index.html is set to <app-weather> if you been skipping around the video like me. Check with ng server first.

vd
Автор

Hey Kalyan, Thanks for the video. Can you please integrate two components created from separate angular applications inside a single HTML page. I tried to create two apps (widget1, widget2) and running into issues when referencing from outside apps in a index.html - Errors regarding duplicate dependencies. One component is always working fine. Thanks

charanbabukarnam
Автор

Can we add routing inside the angular element?

no_one
Автор

thanks for the video. Can you build an angular app and elements from the same project? I'm thinking not.

rygartube
Автор

Can you explain why we need to set target to es2015 ???

connectramprakash
Автор

I got the response from api URL but my code doesn't work, the page is blank.I have followed every step you demonstrated but have not luck.

santunu
Автор

For people whose page is blank please check your paths of weathercard.js
Once i put the absolute path things started working
originally i put -- > <script type="text/javascript" </script> ( as shown in the video)(result : blank page)
later i put -- > <script type="text/javascript" </script> ( result : worked)
I cloned the author's repo thus the above path. So first clone his repo and use the above line index.html that is generated after the build command

Here is the entire index.html code which is working
<!DOCTYPE html>
<html lang="en">
<head>

<meta charset="utf-8">
<title>Weathercard</title>
<base href="/">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="icon" type="image/x-icon" href="favicon.ico">
<link rel="stylesheet"
<body>
<app-weather unit="metric"
</body>
<script type="text/javascript" </script>
</html>


nirajchowdhary
Автор

While generating the html can we automate to remove the correct names of the script file and remove the main.js files as well? Then it becomes a one step process.

pansoftpro
Автор

good video, just please for the future, remove music, its annoying and distracting. Thanks

stefanoslalic
Автор

Hi, first thanks for video.
Your example works fine, but I have problem with call a method of component from HTML, also see my test:
Component:
@Input() location: string;
public options: any = { isOpen: true };

toggle() {
this.options.isOpen = !this.options.isOpen;
}

@Input() log() {
console.log("location", this.location) // Atlanta
console.log("togglee", this.toggle) // undefined
console.log("options", this.options) // undefined
}
HTML:
<app-weather unit="metric"
<script
<script>

</script>.
So, my goal is to pass some options as object on init.

ferhadothman
Автор

Can you show how to pass input parameter to angular element ? And how to handle any event in element ?

pushkarrathod
Автор

Hey brother, music is distracting... :)

vaibsify
Автор

not working on angular 7 at current time

kamalsahmoud
Автор

background music is annoying. Content was good though.

kunalpuri