Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import API from "./api.json";
- import axios from "axios";
- export const getVijestVijestTekst = async (vrstaVijestId, jezikId) => {
- return await axios({
- method: "GET",
- url: API.GETVijestVijestTekst,
- params: {
- vrstaVijestId: vrstaVijestId,
- jezikId: jezikId
- },
- withCredentials: false,
- responseType: "json",
- responseEncoding: "utf8"
- });
- };
- export const getVijestSlika = async slikaNaziv => {
- return await axios({
- method: "GET",
- url: API.GetVijestSlika,
- params: {
- slikaNaziv: slikaNaziv
- },
- withCredentials: false,
- responseType: "stream",
- responseEncoding: "utf8"
- });
- };
- export const onlyUnique = async (value, index, self) => {
- return self.indexOf(value) === index;
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement