Revert yandex ab-test
This commit is contained in:
@@ -13,7 +13,4 @@ COPY --from=builder /app/node_modules node_modules/
|
|||||||
COPY package.json .
|
COPY package.json .
|
||||||
EXPOSE 3000
|
EXPOSE 3000
|
||||||
ENV NODE_ENV=production
|
ENV NODE_ENV=production
|
||||||
|
|
||||||
HEALTHCHECK CMD curl --fail http://localhost:3000 || exit 1
|
|
||||||
|
|
||||||
CMD [ "node", "build" ]
|
CMD [ "node", "build" ]
|
||||||
|
|||||||
62
src/app.html
62
src/app.html
@@ -1,42 +1,32 @@
|
|||||||
<!doctype html>
|
<!doctype html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8" />
|
||||||
|
<link rel="icon" href="%sveltekit.assets%/favicon.png" />
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||||
|
%sveltekit.head%
|
||||||
|
|
||||||
<head>
|
<!-- Yandex.Metrika counter -->
|
||||||
<meta charset="utf-8" />
|
<script type="text/javascript">
|
||||||
<link rel="icon" href="%sveltekit.assets%/favicon.png" />
|
(function (m, e, t, r, i, k, a) {
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
m[i] = m[i] || function () { (m[i].a = m[i].a || []).push(arguments) };
|
||||||
%sveltekit.head%
|
m[i].l = 1 * new Date(); k = e.createElement(t), a = e.getElementsByTagName(t)[0], k.async = 1, k.src = r, a.parentNode.insertBefore(k, a)
|
||||||
|
})
|
||||||
<!-- Yandex.Metrika counter -->
|
|
||||||
<script type="text/javascript">
|
|
||||||
(function (m, e, t, r, i, k, a) {
|
|
||||||
m[i] = m[i] || function () { (m[i].a = m[i].a || []).push(arguments) };
|
|
||||||
m[i].l = 1 * new Date(); k = e.createElement(t), a = e.getElementsByTagName(t)[0], k.async = 1, k.src = r, a.parentNode.insertBefore(k, a)
|
|
||||||
})
|
|
||||||
(window, document, "script", "https://mc.yandex.ru/metrika/tag.js", "ym");
|
(window, document, "script", "https://mc.yandex.ru/metrika/tag.js", "ym");
|
||||||
|
|
||||||
ym(88895893, "init", {
|
ym(88895893, "init", {
|
||||||
clickmap: true,
|
clickmap: true,
|
||||||
trackLinks: true,
|
trackLinks: true,
|
||||||
accurateTrackBounce: true,
|
accurateTrackBounce: true,
|
||||||
webvisor: true,
|
webvisor: true
|
||||||
});
|
|
||||||
|
|
||||||
|
|
||||||
ym(88895893, "getClientID", function (clientID) {
|
|
||||||
ym(88895893, 'userParams', {
|
|
||||||
university_test_group: Number(clientID.slice(-1)) % 2 === 0 ? 'a' : 'b'
|
|
||||||
});
|
});
|
||||||
});
|
</script>
|
||||||
</script>
|
<noscript>
|
||||||
<noscript>
|
<div><img src="https://mc.yandex.ru/watch/88895893" style="position:absolute; left:-9999px;" alt="" /></div>
|
||||||
<div><img src="https://mc.yandex.ru/watch/88895893" style="position:absolute; left:-9999px;" alt="" /></div>
|
</noscript>
|
||||||
</noscript>
|
<!-- /Yandex.Metrika counter -->
|
||||||
<!-- /Yandex.Metrika counter -->
|
</head>
|
||||||
</head>
|
<body data-sveltekit-preload-data="hover">
|
||||||
|
<div style="display: contents">%sveltekit.body%</div>
|
||||||
<body data-sveltekit-preload-data="hover">
|
</body>
|
||||||
<div style="display: contents">%sveltekit.body%</div>
|
</html>
|
||||||
</body>
|
|
||||||
|
|
||||||
</html>
|
|
||||||
|
|||||||
@@ -1,30 +1,19 @@
|
|||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import { onMount } from "svelte";
|
import {t} from "$lib/translations";
|
||||||
import { t } from "$lib/translations";
|
|
||||||
import Project from "./Project.svelte";
|
import Project from "./Project.svelte";
|
||||||
import { projects } from "./projects";
|
import {projects} from "./projects";
|
||||||
|
|
||||||
let wrapperClass = "grid gap-8 md:grid-cols-2 lg:grid-cols-3";
|
|
||||||
|
|
||||||
onMount(() => {
|
|
||||||
window.ym(88895893, "getClientID", function (clientID) {
|
|
||||||
const university_test_group =
|
|
||||||
Number(clientID.slice(-1)) % 2 === 0 ? "a" : "b";
|
|
||||||
if (university_test_group === "b") {
|
|
||||||
wrapperClass = wrapperClass.replace("lg:grid-cols-3", "lg:grid-cols-2")
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<section class="px-2 md:px-8 mb-16 max-w-[1280px] mx-auto">
|
<section class="px-2 md:px-8 mb-16 max-w-[1280px] mx-auto">
|
||||||
<h2 class="text-3xl mb-4 md:text-4xl">
|
<h2 class="text-3xl mb-4 md:text-4xl">
|
||||||
{$t("projects.h")}
|
{$t('projects.h')}
|
||||||
</h2>
|
</h2>
|
||||||
|
|
||||||
<div class={wrapperClass}>
|
<div class="grid gap-8 md:grid-cols-2 lg:grid-cols-3">
|
||||||
{#each projects as project}
|
{#each projects as project}
|
||||||
<Project {project}></Project>
|
<Project
|
||||||
|
project={project}
|
||||||
|
></Project>
|
||||||
{/each}
|
{/each}
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
|
|||||||
Reference in New Issue
Block a user