b5463c41faa4 basic-example "java -jar app.jar" 6 seconds ago Up 2 seconds 0.0.0.0:8086->8085/tcp nifty_babbage
c2cee2839f57 redis:5.0.5-alpine3.9 "docker-entrypoint.s…" 3 days ago Exited (255) 2 days ago 0.0.0.0:6379->6379/tcp redis
-p
docker-compose.yml
через ports:
networks:
IPADDRESS=$(docker inspect $ID | jq -cr '.[]|.NetworkSettings.Networks."basic-elk-cluster_elastic".IPAddress')
echo "IPADDRESS=$IPADDRESS"
export default {
name: 'AuthCallback',
data() {
return {
accessToken: {},
}
},
mounted() {
const tokenParseRegex: RegExp = /access_token=(.*?)&/;
const idParseRegex: RegExp = /user_id(.*?)/;
const exAccessToken: RegExpMatchArray | null = useRoute().hash.match(tokenParseRegex);
this.accessToken = exAccessToken![1]
}
}
const arrA = a[0].trim().split("\n");
// [ "123", "1234", "12345", "123456" ]
const arrB = b[0].trim().split("\n");
// [ "a", "b", "c", "d" ]
const arrAB = arrA.map((str, index) => `${arrB[index]}: ${str}`);
// [ "a: 123", "b: 1234", "c: 12345", "d: 123456" ]
arrAB.join("\n")
/*
"a: 123
b: 1234
c: 12345
d: 123456"
*/
const a = ['123', '1234', '12345', '123456'];
const b = ['a', 'b', 'c', 'd'];
const replace = (search, a, b) => {
const result = a.slice(); // копия
const index = a.indexOf(search);
if (index > -1) result.splice(index, 1, b[index]);
return result;
}
replace('1234', a, b)
// [ "123", "b", "12345", "123456" ]
A double-precision floating-point value indicating the duration of the media in seconds. If no media data is available, the value NaN is returned. If the element's media doesn't have a known duration—such as for live media streams—the value of duration is +Infinity.
audioPlayer.addEventListener('loadedmetadata', function () {
if (audioPlayer.duration == Infinity) {
audioPlayer.currentTime = 1e101;
audioPlayer.ontimeupdate = () => {
this.ontimeupdate = () => {
return;
}
vid.currentTime = 0;
return;
}
}
});
const Start = 1, Finish = 4;
let Sum = Start;
for (let n = Start + 1; n <= Finish; Sum *= n++ ){}
console.log(Sum);
===
это строгое равенство — сравнивает ещё и типы. number === "666" // сравнение со строкой (текстом)
number === 666 // сравнение с числом — то, что надо