case DELETE_SOME_BY_ID:
const byId = { ...state.some.byId };
delete byId[action.payload.id];
const allIdis = state.some.allIdis.filter(el => el.id != action.payload.id);
return {
...state,
some: {
byId,
allIds,
},
};
url: String = '';
ngOnInit() {
this.Preview.url
.subscribe(new_url => this.url = new_url);
}
public previewUrl$: Observable<string>
ngOnInit() {
this.previewUrl$ = this.Preview.url
}
<div class="preview" *ngIf="(previewUrl$ | async) as url">
<img class="preview__img" [src]="url">
</div>
const pictures = [
{ src: 'src1', delay: 1000 },
{ src: 'src2', delay: 2000 },
{ src: 'src3', delay: 3000 },
{ src: 'src4', delay: 4000 },
]
let current = 0;
function nextImage () {
var img = new Image;
img.src = pictures[current].src;
img.onload = function () {
document.body.style.backgroundImage = 'url(' + pictures[current].src + ')';
current++;
if (current >= pictures.length) current = 0;
setTimeout(nextImage, pictures[current].delay);
}
}
nextImage();
onScroll = e => {
if (e.target.offsetHeight + e.target.scrollTop === e.target.scrollHeight) {
/*
* здесь предпринимаете действия, имеющие своим результатом
* демонстрацию дополнительного контента
*/
}
}
<div onScroll={this.onScroll}>
...
<br />
<font size='1'><table class='xdebug-error xe-notice' dir='ltr' border='1' cellspacing='0' cellpadding='1'>
<tr><th align='left' bgcolor='#f57900' colspan="5"><span style='background-color: #cc0000; color: #fce94f; font-size: x-large;'>( ! )</span> Notice: Undefined index: host in /srv/SaraFannTest/public/index.php on line <i>33</i></th></tr>
<tr><th align='left' bgcolor='#e9b96e' colspan='5'>Call Stack</th></tr>
<tr><th align='center' bgcolor='#eeeeec'>#</th><th align='left' bgcolor='#eeeeec'>Time</th><th align='left' bgcolor='#eeeeec'>Memory</th><th align='left' bgcolor='#eeeeec'>Function</th><th align='left' bgcolor='#eeeeec'>Location</th></tr>
<tr><td bgcolor='#eeeeec' align='center'>1</td><td bgcolor='#eeeeec' align='center'>0.0001</td><td bgcolor='#eeeeec' align='right'>356992</td><td bgcolor='#eeeeec'>{main}( )</td><td title='/srv/SaraFannTest/public/index.php' bgcolor='#eeeeec'>.../index.php<b>:</b>0</td></tr>
</table></font>
<br />
<font size='1'><table class='xdebug-error xe-notice' dir='ltr' border='1' cellspacing='0' cellpadding='1'>
<tr><th align='left' bgcolor='#f57900' colspan="5"><span style='background-color: #cc0000; color: #fce94f; font-size: x-large;'>( ! )</span> Notice: Undefined index: scheme in /srv/SaraFannTest/public/index.php on line <i>34</i></th></tr>
<tr><th align='left' bgcolor='#e9b96e' colspan='5'>Call Stack</th></tr>
<tr><th align='center' bgcolor='#eeeeec'>#</th><th align='left' bgcolor='#eeeeec'>Time</th><th align='left' bgcolor='#eeeeec'>Memory</th><th align='left' bgcolor='#eeeeec'>Function</th><th align='left' bgcolor='#eeeeec'>Location</th></tr>
<tr><td bgcolor='#eeeeec' align='center'>1</td><td bgcolor='#eeeeec' align='center'>0.0001</td><td bgcolor='#eeeeec' align='right'>356992</td><td bgcolor='#eeeeec'>{main}( )</td><td title='/srv/SaraFannTest/public/index.php' bgcolor='#eeeeec'>.../index.php<b>:</b>0</td></tr>
</table></font>
fetch("api.kai-zer.ru/dev/method/products.getAll")
.then(r => r.json())
.then(data => {
console.log(data.response);
})