Is the following proposition true?
Let $V$, $W\neq0$ be vector spaces over some field $F$ and let $S_v \subset V$. Then if every mapping $f:S_v \to W$ can be uniquely extended to homomorphism $g:V\to W$, $S_v$ is a basis of $V$.
So far I tried to prove only that $S_v$ can contain only linear independent vectors.
I proceed as follows:
Let every mapping $f:S_v \to W$ be extendable to homomorphism $g:V\to W$. Let $B_v=(b_1,...,b_n)$ be a basis of V. Then it's true that $\forall v \in V$ with coordinates ($c_1,...,c_n$):
$g(v) = g(\sum_{ \substack{i\in \hat{n}}}c_ib_i)=\sum_{{i\in \hat{n}}}c_ig(b_i)$
Moreover let $S_v=(s_1,...,s_m)$ and as $g$ is extension of $f$ : $(\forall s \in S_v) (g(s) = f(s))$.
Then $S_v$ can't be linearly dependent because if it is then:
($\exists c_1,...c_m)((\exists i\in \hat{m})(c_i \neq 0 \wedge \sum_{ \substack{j\in \hat{m}}}c_js_j=0 ) \wedge g(\sum_{ \substack{i\in \hat{m}}}c_is_i)=\sum_{ \substack{i\in \hat{m}}}c_if(s_i) = 0)$
and that won't hold for all possible mappings $f$.
Can I somehow proceed further and prove that $S_v$ is basis?
I tried to define a homomorphism on $V$. Knowing that $S_v$ is linearly independent I can extend it to basis $B'_v = (s_1, ..., s_m, b'_{m+1}, ... , b'_n)$ and define $g$ also to map $(b'_{m+1}, ... , b'_n) \to W $.
At the end I will have:
$(\forall v \in V)(\exists c_1,...,c_n) (g(v) = g(\sum_{ {i\in \hat{m}}}c_is_i+\sum_{ {m<j\leq n}}c_jb'_i) = \sum_{ {i\in \hat{m}}}c_if(s_i)+\sum_{ {m<j\leq n}}c_jg(b'_i)))$.
But it won't be a unique extension because I can extend $S_v$ to basis in different ways. So the only option is to have $S_v$ as basis already.
Does this correctly prove that the proposition is true?
Corrections compared to the first version: forgot to mention uniqueness of extension, added restriction $W\neq0$.
It works if you assume that $dim(W)\ge dim(V)$, as pointed out in the comments. I will assume that $W=V$ as it is the simplest case, and all other cases are a corollary of it.
Let $S_V=\{s_1, \dots \}$. Let $U=Span(S_V)$. Then we have that the map $f:S_V\to V$ given by $v\mapsto v$ can be extended to the identity map $V\to V$, and the map given by projection $V\to U$ both extend $f$, so they must coincide, and $U=Im(Pr_U)=Im(Id)=V$, so $S_V$ is a spanning set.
For independence, assume that $s_i=\sum_{i\neq j} a_js_j$. Then we have a map $f_i:S_V\to V$ given by $s_j\mapsto 0$ for $j\neq i$, and $s_i\mapsto s_i$. By assumption, this extends to $f:V\to V$. So that $s_i=f(s_i)=f(\sum_j a_js_j)=\sum_i a_jf(s_j)=0$. But if $s_i=0$, then the map $f:S_V\to V$ given by $s_i\mapsto 1$ has $1=f(s_i)=f(0)=f(2*0)=f(2s_i)=2$, a contradiction. Thus we have that the $s_j$ are independent, so that $S_V$ forms a basis as desired.